Fix: Dereference of null pointer in FDialog

This commit is contained in:
Markus Gans 2016-09-11 17:26:41 +02:00
parent e462db30a9
commit 9551924b73
3 changed files with 3 additions and 7 deletions

View File

@ -20,8 +20,6 @@ Missing Features
└──► tmp
---------------------------------------
- FDialog title button [▲] and [▼] should maximized or restore
the window size on a resizeable dialog
- A possibility to change the window size dynamically with the mouse
- Add a scrolling area with on-demand scroll bars for FButtonGroup
- Adding for flexible layouts a FGrid widget container that organizes

View File

@ -1686,7 +1686,7 @@ int FApplication::processTimerEvent()
//----------------------------------------------------------------------
void FApplication::processTerminalUpdate()
{
#define MAX_SKIP 8
const int max_skip = 8;
if ( terminal_update_pending )
{
@ -1696,7 +1696,7 @@ void FApplication::processTerminalUpdate()
terminal_update_pending = false;
skipped_terminal_update = 0;
}
else if ( skipped_terminal_update > MAX_SKIP )
else if ( skipped_terminal_update > max_skip )
{
force_terminal_update = true;
updateTerminal();
@ -1707,8 +1707,6 @@ void FApplication::processTerminalUpdate()
else
skipped_terminal_update++;
}
#undef MAX_SKIP
}
//----------------------------------------------------------------------

View File

@ -233,7 +233,7 @@ void FDialog::drawTitleBar()
// draw the title button
gotoxy (xpos+xmin-1, ypos+ymin-1);
if ( dialog_menu->isVisible() )
if ( dialog_menu && dialog_menu->isVisible() )
setColor (wc.titlebar_button_focus_fg, wc.titlebar_button_focus_bg);
else
setColor (wc.titlebar_button_fg, wc.titlebar_button_bg);