Subversion Repositories svn.mios32

Rev

Rev 1724 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1724 Rev 2180
Line 1... Line 1...
1
/* -*- mode:C++; tab-width:4; c-basic-offset:4; indent-tabs-mode:nil -*- */
1
/* -*- mode:C++; tab-width:4; c-basic-offset:4; indent-tabs-mode:nil -*- */
2
// $Id: HexTextEditor.cpp 1724 2013-03-28 20:23:40Z tk $
2
// $Id: HexTextEditor.cpp 2180 2015-06-14 19:21:59Z tk $
3
/*
3
/*
4
 * Text Editor variant which allows to edit hex bytes
4
 * Text Editor variant which allows to edit hex bytes
5
 *
5
 *
6
 * ==========================================================================
6
 * ==========================================================================
7
 *
7
 *
Line 86... Line 86...
86
    if( charCounter > 0 )
86
    if( charCounter > 0 )
87
        ++numBytes;
87
        ++numBytes;
88
88
89
    if( isEnabled() && isVisible() ) {
89
    if( isEnabled() && isVisible() ) {
90
        if( invalidBytesFound )
90
        if( invalidBytesFound )
91
            statusLabel->setText(T("Invalid Syntax!"), true);
91
            statusLabel->setText(T("Invalid Syntax!"), sendNotification);
92
        else if( numBytes == 0 )
92
        else if( numBytes == 0 )
93
            statusLabel->setText(String::empty, true);
93
            statusLabel->setText(String::empty, sendNotification);
94
        else if( numBytes == 1 )
94
        else if( numBytes == 1 )
95
            statusLabel->setText(T("1 byte"), true);
95
            statusLabel->setText(T("1 byte"), sendNotification);
96
        else
96
        else
97
            statusLabel->setText(String(numBytes) + T(" bytes"), true);
97
            statusLabel->setText(String(numBytes) + T(" bytes"), sendNotification);
98
    }
98
    }
99
}
99
}
100
100
101
void HexTextEditor::textEditorReturnKeyPressed(TextEditor &editor)
101
void HexTextEditor::textEditorReturnKeyPressed(TextEditor &editor)
102
{
102
{