View | Details | Raw Unified | Return to bug 13149
Collapse All | Expand All

(-)knemo-0.4.8/src/kcm/configdialog.cpp~ (-2 / +2 lines)
Lines 269-275 void ConfigDialog::load() Link Here
269
269
270
    // select the backend from the config file
270
    // select the backend from the config file
271
    bool foundBackend = false;
271
    bool foundBackend = false;
272
    QString backend = config->readEntry( "Backend", "Nettools" );
272
    QString backend = config->readEntry( "Backend", "Sys" );
273
    int i;
273
    int i;
274
    for ( i = 0; KCMRegistry[i].name != QString::null; i++ )
274
    for ( i = 0; KCMRegistry[i].name != QString::null; i++ )
275
    {
275
    {
Lines 282-288 void ConfigDialog::load() Link Here
282
282
283
    if ( !foundBackend )
283
    if ( !foundBackend )
284
    {
284
    {
285
        i = 0; // use the first backend (Nettools)
285
        i = 0; // use the first backend (Sys)
286
    }
286
    }
287
    mDlg->comboBoxBackends->setCurrentItem( i );
287
    mDlg->comboBoxBackends->setCurrentItem( i );
288
    mDlg->textLabelBackendDescription->setText( KCMRegistry[i].description );
288
    mDlg->textLabelBackendDescription->setText( KCMRegistry[i].description );
(-)knemo-0.4.8/src/knemod/backends/daemonregistry.h~ (-1 / +1 lines)
Lines 46-53 struct DaemonRegistryEntry Link Here
46
46
47
DaemonRegistryEntry DaemonRegistry[] =
47
DaemonRegistryEntry DaemonRegistry[] =
48
{
48
{
49
    { "Nettools", NetToolsBackend::createInstance },
50
    { "Sys", SysBackend::createInstance },
49
    { "Sys", SysBackend::createInstance },
50
    { "Nettools", NetToolsBackend::createInstance },
51
    { QString::null, 0 }
51
    { QString::null, 0 }
52
};
52
};
53
53
(-)knemo-0.4.8/src/knemod/backends/kcmregistry.h~ (-6 / +6 lines)
Lines 42-53 struct KCMRegistryEntry Link Here
42
42
43
KCMRegistryEntry KCMRegistry[] =
43
KCMRegistryEntry KCMRegistry[] =
44
{
44
{
45
    { "Nettools",
46
      i18n( "Uses the tools from the nettool packge like ifconfig, "    \
47
            "iwconfig and route to read the necessary information "     \
48
            "from the ouput of these commands.\n"                       \
49
            "This backend works rather stable but causes a relativly "  \
50
            "high CPU load." ) },
51
    { "Sys",
45
    { "Sys",
52
      i18n( "Uses the sys filesystem available in 2.6 kernels and "     \
46
      i18n( "Uses the sys filesystem available in 2.6 kernels and "     \
53
            "direct system calls to the Linux kernel.\n"                \
47
            "direct system calls to the Linux kernel.\n"                \
Lines 55-60 KCMRegistryEntry KCMRegistry[] = Link Here
55
            "As an advantage this backend should reduce the CPU load "  \
49
            "As an advantage this backend should reduce the CPU load "  \
56
            "and should not access the harddisc while gathering "       \
50
            "and should not access the harddisc while gathering "       \
57
            "information." ) },
51
            "information." ) },
52
    { "Nettools",
53
      i18n( "Uses the tools from the nettool packge like ifconfig, "    \
54
            "iwconfig and route to read the necessary information "     \
55
            "from the ouput of these commands.\n"                       \
56
            "This backend works rather stable but causes a relativly "  \
57
            "high CPU load." ) },
58
    { QString::null, QString::null }
58
    { QString::null, QString::null }
59
};
59
};
60
60
(-)knemo-0.4.8/src/knemod/knemodaemon.cpp~ (-3 / +3 lines)
Lines 58-64 KNemoDaemon::KNemoDaemon( const QCString Link Here
58
    // select the backend from the config file
58
    // select the backend from the config file
59
    KConfig* config = new KConfig( "knemorc", true );
59
    KConfig* config = new KConfig( "knemorc", true );
60
    config->setGroup( "General" );
60
    config->setGroup( "General" );
61
    mBackendName = config->readEntry( "Backend", "Nettools" );
61
    mBackendName = config->readEntry( "Backend", "Sys" );
62
    delete config;
62
    delete config;
63
63
64
    bool foundBackend = false;
64
    bool foundBackend = false;
Lines 74-80 KNemoDaemon::KNemoDaemon( const QCString Link Here
74
74
75
    if ( !foundBackend )
75
    if ( !foundBackend )
76
    {
76
    {
77
        i = 0; // use the first backend (Nettools)
77
        i = 0; // use the first backend (Sys)
78
    }
78
    }
79
    mBackend = ( *DaemonRegistry[i].function )( mInterfaceDict );
79
    mBackend = ( *DaemonRegistry[i].function )( mInterfaceDict );
80
80
Lines 195-201 void KNemoDaemon::reparseConfiguration() Link Here
195
    mPollTimer->changeInterval( mGeneralData.pollInterval * 1000 );
195
    mPollTimer->changeInterval( mGeneralData.pollInterval * 1000 );
196
196
197
    // select the backend from the config file
197
    // select the backend from the config file
198
    QString backend = config->readEntry( "Backend", "Nettools" );
198
    QString backend = config->readEntry( "Backend", "Sys" );
199
199
200
    if ( mBackendName != backend )
200
    if ( mBackendName != backend )
201
    {
201
    {

Return to bug 13149