Author: gs
Date: Thu Sep 6 12:07:11 2007
New Revision: 40779
URL: http://svn.opensuse.org/viewcvs/yast?rev=40779&view=rev
Log:
make focusNext/Prev work
Modified:
branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.cc
branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.h
Modified: branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.cc
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.cc?rev=40779&r1=40778&r2=40779&view=diff
==============================================================================
--- branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.cc (original)
+++ branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.cc Thu Sep 6 12:07:11 2007
@@ -102,12 +102,11 @@
{
int n = 0;
- if ( focusId < radioButtonsCount() -1 )
+ if ( focusId < radioButtonsCount() )
focusId++;
- else if ( focusId == radioButtonsCount() -1 )
+ else if ( focusId == radioButtonsCount() )
focusId = 0;
- // FIXME
for ( YRadioButtonListConstIterator it = radioButtonsBegin();
it != radioButtonsEnd();
++it )
@@ -122,12 +121,6 @@
}
}
}
-
-#if 0
- NCRadioButton * button = dynamic_cast(buttonlist[focusId]);
- if ( button )
- button->setKeyboardFocus();
-#endif
}
///////////////////////////////////////////////////////////////////
@@ -147,7 +140,6 @@
else if ( focusId == 0 )
focusId = radioButtonsCount() -1;
- // FIXME
for ( YRadioButtonListConstIterator it = radioButtonsBegin();
it != radioButtonsEnd();
++it )
@@ -162,12 +154,6 @@
}
}
}
-
-#if 0
- NCRadioButton * button = dynamic_cast(buttonlist[focusId]);
- if ( button )
- button->setKeyboardFocus();
-#endif
}
void NCRadioButtonGroup::setEnabled( bool do_bv )
Modified: branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.h
URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.h?rev=40779&r1=40778&r2=40779&view=diff
==============================================================================
--- branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.h (original)
+++ branches/tmp/sh/mod-ui/ncurses/src/NCRadioButtonGroup.h Thu Sep 6 12:07:11 2007
@@ -41,7 +41,7 @@
NCRadioButtonGroup ( const NCRadioButtonGroup & );
private:
- unsigned int focusId;
+ int focusId;
protected:
@@ -52,7 +52,6 @@
NCRadioButtonGroup( YWidget * parent );
virtual ~NCRadioButtonGroup();
- //virtual long nicesize( YUIDimension dim ) { return YRadioButtonGroup::nicesize( dim ); }
virtual int preferredWidth() { return YRadioButtonGroup::preferredWidth(); }
virtual int preferredHeight() { return YRadioButtonGroup::preferredHeight(); }
@@ -66,7 +65,6 @@
virtual void addRadioButton(YRadioButton *button);
virtual void removeRadioButton(YRadioButton *button);
- //virtual void setEnabling( bool do_bv );
virtual void setEnabled( bool do_bv );
void focusNextButton( );
--
To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org
For additional commands, e-mail: yast-commit+help@opensuse.org