コード例 #1
0
ファイル: dlgoptn.c プロジェクト: ABratovic/open-watcom-v2
static void GetDlgStatus( gui_window *gui )
{
    long        tmp;
    unsigned    old;

    old = NewCurrRadix( 10 );
    _SwitchSet( SW_AUTO_SAVE_CONFIG, GUIIsChecked( gui, CTL_OPT_AUTO ) );
    _SwitchSet( SW_BELL, GUIIsChecked( gui, CTL_OPT_BELL ) );
    _SwitchSet( SW_IMPLICIT, GUIIsChecked( gui, CTL_OPT_IMPLICIT ) );
    _SwitchSet( SW_RECURSE_CHECK, GUIIsChecked( gui, CTL_OPT_RECURSE ) );
    _SwitchSet( SW_FLIP, GUIIsChecked( gui, CTL_OPT_FLIP ) );
    _SwitchSet( SW_DONT_EXPAND_HEX, GUIIsChecked( gui, CTL_OPT_NOHEX ) );
    LookCaseSet( !GUIIsChecked( gui, CTL_OPT_CASE ) );
    if( DlgGetLong( gui, CTL_OPT_RADIX, &tmp ) ) {
        DefaultRadixSet( tmp );
        old = NewCurrRadix( 10 );
    }
    if( DlgGetLong( gui, CTL_OPT_DCLICK, &tmp ) ) {
        WndSetDClick( tmp );
    }
    NewCurrRadix( old );

    /* Don't change config if it is just the trap file that does not support the option! */
    if( SupportsExactBreakpoints ) {
        _SwitchSet( SW_BREAK_ON_WRITE, GUIIsChecked( gui, CTL_OPT_BR_ON_WRITE ) );
        CapabilitiesSetExactBreakpointSupport( _IsOn( SW_BREAK_ON_WRITE ) ? TRUE : FALSE );
    }
}
コード例 #2
0
ファイル: dbgscan.c プロジェクト: Ukusbobra/open-watcom-v2
void RadixSet( void )
{
    unsigned   radix;
    unsigned   old;

    old = SetCurrRadix( 10 ); /* radix sets are always base 10 */
    radix = ReqExpr();
    ReScan( TokenStart );
    ReqEOC();
    if( radix < 2 || radix > 36 ) {
        Error( ERR_NONE, LIT( ERR_BAD_RADIX ), radix );
    }
    SetCurrRadix( old );
    DefaultRadixSet( radix );
}