Remove setVisibleCursor() from the FToggleButton class constructor

This commit is contained in:
Markus Gans 2015-08-11 00:11:07 +02:00
parent 292469f5b5
commit df6636bf60
8 changed files with 9 additions and 10 deletions

View File

@ -1064,7 +1064,7 @@ void FApplication::processMouseEvent()
} }
} }
flush_out(); flush_out();
#ifdef HAVE_LIBGPM #ifdef HAVE_LIBGPM
if ( gpm_mouse_enabled && gpm_ev.x != -1 ) if ( gpm_mouse_enabled && gpm_ev.x != -1 )
GPM_DRAWPOINTER(&gpm_ev); GPM_DRAWPOINTER(&gpm_ev);

View File

@ -34,6 +34,7 @@ void FCheckBox::init()
{ {
label_offset_pos = 4; label_offset_pos = 4;
button_width = 4; button_width = 4;
setVisibleCursor();
} }
//---------------------------------------------------------------------- //----------------------------------------------------------------------

View File

@ -11,7 +11,7 @@
FWindow FMenuBar FWindow FMenuBar
FMenuList ------- FMenuItem FMenuList ------- FMenuItem

View File

@ -35,6 +35,7 @@ void FRadioButton::init()
{ {
label_offset_pos = 4; label_offset_pos = 4;
button_width = 4; button_width = 4;
setVisibleCursor();
} }
//---------------------------------------------------------------------- //----------------------------------------------------------------------

View File

@ -65,7 +65,7 @@ void FSwitch::drawCheckButton()
{ {
if ( hasFocus() && ! button_pressed ) if ( hasFocus() && ! button_pressed )
{ {
if ( isMonochron() || getMaxColor() < 16 ) if ( isMonochron() || getMaxColor() < 16 )
{ {
wcsncpy ( on, L" <On>", 6); wcsncpy ( on, L" <On>", 6);

View File

@ -3391,7 +3391,7 @@ FString FTerm::getAnswerbackMsg()
usleep(150000); // wait 150 ms usleep(150000); // wait 150 ms
// read the answerback message // read the answerback message
if ( read(fileno(stdin), &temp, sizeof(temp)-1) > 0 ) if ( read(fileno(stdin), &temp, sizeof(temp)-1) > 0 )
answerback = temp; answerback = temp;
} }
return answerback; return answerback;
} }

View File

@ -65,9 +65,6 @@ void FToggleButton::init()
setGeometry (1, 1, 4, 1, false); // initialize geometry values setGeometry (1, 1, 4, 1, false); // initialize geometry values
if ( isRadioButton() || isCheckboxButton() )
setVisibleCursor();
if ( hasFocus() ) if ( hasFocus() )
this->flags = FOCUS; this->flags = FOCUS;
@ -157,7 +154,7 @@ void FToggleButton::draw()
if ( isRadioButton() || isCheckboxButton() ) if ( isRadioButton() || isCheckboxButton() )
{ {
setCursorPos (xpos+xmin, ypos+ymin-1); setCursorPos (xpos+xmin, ypos+ymin-1);
if ( isCursorInside() && hasFocus() ) if ( isCursorInside() && hasFocus() )
{ {
if ( isHiddenCursor() ) if ( isHiddenCursor() )

View File

@ -67,7 +67,7 @@ watch::watch (FWidget* parent) : FDialog(parent)
FButton* quit = new FButton(L"&Quit", this); FButton* quit = new FButton(L"&Quit", this);
quit->setGeometry(6, 9, 9, 1); quit->setGeometry(6, 9, 9, 1);
quit->setShadow(); quit->setShadow();
// Connect switch signal "toggled" with a callback member function // Connect switch signal "toggled" with a callback member function
clock_sw->addCallback clock_sw->addCallback
@ -109,7 +109,7 @@ void watch::printTime()
FString str; FString str;
struct tm* now; struct tm* now;
time_t t; time_t t;
t = time(0); // get current time t = time(0); // get current time
now = localtime(&t); now = localtime(&t);