Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > More E-Book Readers > iRex > iRex Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 12-22-2010, 01:11 PM   #1
Mackx
Guru
Mackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to beholdMackx is a splendid one to behold
 
Posts: 999
Karma: 19985
Join Date: Dec 2008
Location: Netherlands
Device: iRex DR1000S
Screen refreshes

I am currently struggling with screen updates (for the find-dialog of FBReader). I am using the erutils-functions with a wrapper file I copied from notepad (notepad_display_sched.cpp).
I saw that in notepad the following calls are made:
Code:
                    notepad_stop_display_update();
                    GtkWidget* infodialog = gtk_message_dialog_new(...)
                    notepad_on_timeout_display_yield(400, DM_HINT_FULL);
                    gtk_dialog_run(GTK_DIALOG(infodialog));
If I use the same order of instructions (stop_display_update(), create part of the dialog and then on_timeout_display_yield() ) I do not get a screen update, so the dialog is not shown. Also calling stop_display_update(), display_update((void*)DM_HINT_FULL) and start_display_update() does not lead to an update.

My modified function:
Spoiler:
bool ZLGtkDialog::run() {
bool ok;

printf("ZLGtkDialog::run\n");
// stop refresh, to be able to force a refresh
dr_stop_display_update();
if (!myIsPacked) {
gtk_box_pack_start(GTK_BOX(myDialog->vbox), GTK_WIDGET(((ZLGtkDialogContent*)myTab)->widget()), true, true, 0);
myIsPacked = true;
}
gtk_widget_show_all(GTK_WIDGET(myDialog));
// refresh screen
dr_on_timeout_display_yield(400, DM_HINT_FULL);

printf("ZLGtkDialog::run-before\n");
ok = gtk_dialog_run(GTK_DIALOG(myDialog)) == GTK_RESPONSE_ACCEPT;

// stop refresh, to be able to force a refresh
dr_stop_display_update();
dr_display_update((void*)DM_HINT_FULL);
dr_start_display_update();

return ok;
}


I assume I am missing some clues, is there anyone with some more experience to give me some hints on how to continue?

Thanks,
Marcel

Last edited by Mackx; 12-22-2010 at 01:16 PM.
Mackx is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
302 screen versus the Sony PRS-600 screen bill_mchale PocketBook 2 09-22-2010 09:43 AM
Reader with 6 inch screen, but no Tocuh screen? Cyclops Sony Reader 2 09-05-2010 01:26 PM
broken screen. is there a program that skims off top one inch of screen? pennpin Sony Reader 5 08-19-2009 04:42 PM
And you thought E Ink refreshes were slow? Check Kent... TadW News 2 06-05-2007 09:13 AM


All times are GMT -4. The time now is 09:20 PM.


MobileRead.com is a privately owned, operated and funded community.