![]() |
#1 |
0000000000101010
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,659
Karma: 11226897
Join Date: Mar 2023
Location: An island off the coast of Ireland
Device: PB632 [HD3]
|
dialog - ELF binary - Parameter for no buttons?
I've been playing with the built-in "dialog" binary:
/ebrmain/cramfs/bin/dialog I understand that a message box can be called via: Code:
dialog n "title" "message" "b1" "b2" "b3" Where n determines an icon to be shown by choosing 1-5:
Any number that's not 1-5 will not display an icon. I'm not sure what the title field does, as entering anything here isn't displayed on the message box itself. My guess is that it's a title for the individual message box process? The message field is self-explanatory and no problems there. You can display up to 3 buttons. BUT even if you don't specify any buttons at all (blank line after message) if defaults to a single button. I'm sure I have seen system apps use dialog messages without a button, so I'm thinking there must be a parameter for this? Does anybody know what it might be, or how I could find out? I've examined the ELF binary via a hex editor and via dumpelf but haven't been able to glean any insight. EDIT: rkomar pointed me in the right direction, the dialog binary uses the "dialog" inkview function which requires at least one button. The "message" function has a timeout and no buttons. Message (int icon, char *title, char *text, int timeout) Dialog (int icon, char *title, char *text, char *button1, char *button2, iv_dialoghandler hproc) Last edited by neil_swann80; 04-25-2023 at 12:13 AM. |
![]() |
![]() |
![]() |
#2 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,006
Karma: 18346231
Join Date: Oct 2010
Location: Sudbury, ON, Canada
Device: PRS-505, PB 902, PRS-T1, PB 623, PB 840, PB 633
|
How do you make it go away if you don't have a button to click? Typically, you provide a timeout value if you don't want any buttons, but you aren't showing any option for that above.
Edit: Besides, a "dialog" means some kind of interaction. What you are thinking of is a "message", which typically has a timeout value to make it disappear on its own. Last edited by rkomar; 04-20-2023 at 04:42 PM. |
![]() |
![]() |
![]() |
#3 |
0000000000101010
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,659
Karma: 11226897
Join Date: Mar 2023
Location: An island off the coast of Ireland
Device: PB632 [HD3]
|
Either a timeout or the entire message box itself becomes a clickable ok/cancel button.
When you mentioned the strange functions associated with the "iv2sh" binary (regarding the reboot command), how did you view those functions? (ah, just calling it in terminal spits out the functions.) If there is a timeout function, is there a way to find the parameter that initiates it from the binary? And any other valid parameters? Last edited by neil_swann80; 04-21-2023 at 09:36 AM. |
![]() |
![]() |
![]() |
#4 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,006
Karma: 18346231
Join Date: Oct 2010
Location: Sudbury, ON, Canada
Device: PRS-505, PB 902, PRS-T1, PB 623, PB 840, PB 633
|
I don't think there is a timeout parameter. The help information just displays the Dialog functions from the Inkview API that are called inside the program. Neither takes a timeout argument because dialogs require an answer of some kind, so they will wait forever until they get one.
If you want to display a message and go away after a timeout, I think you will have write your own program that calls the Inkview API Message() function. I glanced through the programs on my Colour, and I don't see anything that obviously does that already. |
![]() |
![]() |
![]() |
#5 |
0000000000101010
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,659
Karma: 11226897
Join Date: Mar 2023
Location: An island off the coast of Ireland
Device: PB632 [HD3]
|
Yep, of course you're correct about the Inkview API Message() function.
I'll have a crack at writing a simple program. https://github.com/dennwc/inkview This suggests that a program compiled in GO shouldn't even require the SDK. On a different note, do you happen to know where the browser.app cookies are stored? |
![]() |
![]() |
![]() |
#6 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,006
Karma: 18346231
Join Date: Oct 2010
Location: Sudbury, ON, Canada
Device: PRS-505, PB 902, PRS-T1, PB 623, PB 840, PB 633
|
No, I have never looked for them. Most things are stored somewhere in the /system/ directory, so you should be able to find them there. That part of the file system is accessible over UMS, so you can look for it with your desktop software if you mount the filesystem over USB.
|
![]() |
![]() |
![]() |
#7 |
0000000000101010
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,659
Karma: 11226897
Join Date: Mar 2023
Location: An island off the coast of Ireland
Device: PB632 [HD3]
|
Found it!
SQLite file: /mnt/ext1/system/state/storage/browser/cookies I was hoping for a simple text file. Editing this on the device itself could be tricky. I'm sure I saw a post somewhere that showed python working on Pocketbook devices. Perhaps I can get PySQLite working. Last edited by neil_swann80; 04-24-2023 at 03:59 AM. |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Help needed on a search parameter | jecilop | Library Management | 2 | 03-19-2017 10:27 AM |
Position of Buttons in Dialog Boxes | wrightsl | Calibre | 44 | 10-29-2014 10:14 PM |
"ELF binary type "0" not known" Error. When run Kindlegen | chovan | Amazon Kindle | 4 | 02-09-2012 11:49 AM |
Multiple feeds with different parameter | yeFoenix | Recipes | 0 | 01-28-2012 07:34 AM |