Subversion Repositories svn.mios32

Rev

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

Rev 1502 Rev 1724
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: OscTool.cpp 1502 2012-09-05 22:25:07Z tk $
2
// $Id: OscTool.cpp 1724 2013-03-28 20:23:40Z tk $
3
/*
3
/*
4
 * OSC Tool Window
4
 * OSC Tool Window
5
 *
5
 *
6
 * ==========================================================================
6
 * ==========================================================================
7
 *
7
 *
Line 69... Line 69...
69
    disconnectButton->setButtonText(T("Disconnect"));
69
    disconnectButton->setButtonText(T("Disconnect"));
70
    disconnectButton->setEnabled(false);
70
    disconnectButton->setEnabled(false);
71
    disconnectButton->addListener(this);
71
    disconnectButton->addListener(this);
72
72
73
    // restore settings
73
    // restore settings
74
    PropertiesFile *propertiesFile = ApplicationProperties::getInstance()->getCommonSettings(true);
74
    PropertiesFile *propertiesFile = MiosStudioProperties::getInstance()->getCommonSettings(true);
75
    if( propertiesFile ) {
75
    if( propertiesFile ) {
76
        remoteHostLine->setText(propertiesFile->getValue(T("oscRemoteHost"), String::empty));
76
        remoteHostLine->setText(propertiesFile->getValue(T("oscRemoteHost"), String::empty));
77
        portNumberWriteLine->setText(propertiesFile->getValue(T("oscPortWrite"), "10000"));
77
        portNumberWriteLine->setText(propertiesFile->getValue(T("oscPortWrite"), "10000"));
78
        portNumberReadLine->setText(propertiesFile->getValue(T("oscPortRead"), "10000"));
78
        portNumberReadLine->setText(propertiesFile->getValue(T("oscPortRead"), "10000"));
79
    }
79
    }
Line 110... Line 110...
110
//==============================================================================
110
//==============================================================================
111
void OscToolConnect::buttonClicked(Button* buttonThatWasClicked)
111
void OscToolConnect::buttonClicked(Button* buttonThatWasClicked)
112
{
112
{
113
    if( buttonThatWasClicked == connectButton ) {
113
    if( buttonThatWasClicked == connectButton ) {
114
        // store settings
114
        // store settings
115
        PropertiesFile *propertiesFile = ApplicationProperties::getInstance()->getCommonSettings(true);
115
        PropertiesFile *propertiesFile = MiosStudioProperties::getInstance()->getCommonSettings(true);
116
        if( propertiesFile ) {
116
        if( propertiesFile ) {
117
            propertiesFile->setValue(T("oscRemoteHost"), remoteHostLine->getText());
117
            propertiesFile->setValue(T("oscRemoteHost"), remoteHostLine->getText());
118
            propertiesFile->setValue(T("oscPortWrite"), portNumberWriteLine->getText());
118
            propertiesFile->setValue(T("oscPortWrite"), portNumberWriteLine->getText());
119
            propertiesFile->setValue(T("oscPortRead"), portNumberReadLine->getText());
119
            propertiesFile->setValue(T("oscPortRead"), portNumberReadLine->getText());
120
        }
120
        }