Author: kmachalkova Date: Tue Oct 23 15:06:36 2007 New Revision: 41524 URL: http://svn.opensuse.org/viewcvs/yast?rev=41524&view=rev Log: Fixed some operator priority Modified: trunk/ncurses/src/NCRichText.h trunk/ncurses/src/NCstyle.h Modified: trunk/ncurses/src/NCRichText.h URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/NCRichText.h?rev=41524&r1=41523&r2=41524&view=diff ============================================================================== --- trunk/ncurses/src/NCRichText.h (original) +++ trunk/ncurses/src/NCRichText.h Tue Oct 23 15:06:36 2007 @@ -142,7 +142,7 @@ if ( sline == unset || scol == unset || eline == unset || ecol == unset ) return false; - if ( eline == sline && ecol <= scol + if ( ( eline == sline && ecol <= scol ) || eline < sline ) return false; return true; Modified: trunk/ncurses/src/NCstyle.h URL: http://svn.opensuse.org/viewcvs/yast/trunk/ncurses/src/NCstyle.h?rev=41524&r1=41523&r2=41524&view=diff ============================================================================== --- trunk/ncurses/src/NCstyle.h (original) +++ trunk/ncurses/src/NCstyle.h Tue Oct 23 15:06:36 2007 @@ -75,13 +75,13 @@ inline static chtype getChar ( chtype a ) { return a & char_mask; } inline static chtype getNonChar ( chtype a ) { return a & ~char_mask; } - inline static void setStyle ( chtype & a, chtype ch ) { a = a & ~style_mask | ch & style_mask; } - inline static void setColor ( chtype & a, chtype ch ) { if ( colors() ) a = a & ~color_mask | ch & color_mask; } - inline static void setChar ( chtype & a, chtype ch ) { a = a & ~char_mask | ch & char_mask; } + inline static void setStyle ( chtype & a, chtype ch ) { a = (a & ~style_mask) | (ch & style_mask); } + inline static void setColor ( chtype & a, chtype ch ) { if ( colors() ) a = (a & ~color_mask) | (ch & color_mask); } + inline static void setChar ( chtype & a, chtype ch ) { a = (a & ~char_mask) | (ch & char_mask); } - inline static void addStyle ( chtype & a, chtype ch ) { a = a | ch & style_mask; } + inline static void addStyle ( chtype & a, chtype ch ) { a = a | (ch & style_mask); } inline static void delStyle ( chtype & a, chtype ch ) { a = a & ~(ch & style_mask); } - inline static void toggleStyle( chtype & a, chtype ch ) { setStyle( a, a & ~ch | (a ^ ch) & ch ); } + inline static void toggleStyle( chtype & a, chtype ch ) { setStyle( a, (a & ~ch) | ((a ^ ch) & ch )); } inline static void addAlt ( chtype & a ) { a |= A_ALTCHARSET; } inline static void delAlt ( chtype & a ) { a &= ~A_ALTCHARSET; } -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org