Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 141062 | Differences between
and this patch

Collapse All | Expand All

(-)komics/src/main.cpp.orig (-9 / +10 lines)
Lines 23-41 Link Here
23
                       I18N_NOOP(__comment), KAboutData::License_GPL_V2,
23
                       I18N_NOOP(__comment), KAboutData::License_GPL_V2,
24
                       "(C) 2003 Natella Roberto", 0, "roberto.natella@virgilio.it" );
24
                       "(C) 2003 Natella Roberto", 0, "roberto.natella@virgilio.it" );
25
25
26
    about.addAuthor("Roberto Natella", 0,
26
	about.addAuthor("Roberto Natella", 0,
27
                    "roberto.natella@virgilio.it", "http://www.orson.it/" );
27
					"roberto.natella@virgilio.it", "http://www.orson.it/" );
28
28
29
    KCmdLineArgs::init( argc, argv, &about);
29
	KCmdLineArgs::init( argc, argv, &about);
30
30
31
    KApplication::disableAutoDcopRegistration();
31
	KApplication::disableAutoDcopRegistration();
32
33
	if (!KUniqueApplication::start()) {
34
		sprintf(stderr, i18n( QString("Unable to start the application. Another instance was already started.") ));
35
		exit(0);
36
	}
32
    KUniqueApplication app;
37
    KUniqueApplication app;
33
38
34
    if( !Komics::lock() )
35
        return -1;
36
39
37
    Komics * komics = new Komics(0,new KConfig("libkomicsrc"));
40
    Komics * komics = new Komics(0,new KConfig("libkomicsrc"));
38
    
41
39
    if( komics == NULL )
42
    if( komics == NULL )
40
        return -1;
43
        return -1;
41
44
Lines 46-53 Link Here
46
    int ret = app.exec();
49
    int ret = app.exec();
47
    delete komics;
50
    delete komics;
48
51
49
    Komics::unlock();
50
51
    return ret;
52
    return ret;
52
}
53
}
53
54
(-)komics/src/komics.cpp.orig (-6 / +5 lines)
Lines 1314-1320 Link Here
1314
    
1314
    
1315
    return url;
1315
    return url;
1316
}
1316
}
1317
1317
/*
1318
bool Komics::lock()
1318
bool Komics::lock()
1319
{
1319
{
1320
    QString lock = locateLocal("data", "komics/lock");
1320
    QString lock = locateLocal("data", "komics/lock");
Lines 1344-1354 Link Here
1344
1344
1345
    return true;
1345
    return true;
1346
}
1346
}
1347
1347
*/
1348
void Komics::shutDown()
1348
void Komics::shutDown()
1349
{
1349
{
1350
    writeHistory();
1350
    writeHistory();
1351
    unlock();
1352
}
1351
}
1353
1352
1354
KomicsApplet::KomicsApplet(const QString& configFile, Type type, int actions, QWidget *parent, const char *name)
1353
KomicsApplet::KomicsApplet(const QString& configFile, Type type, int actions, QWidget *parent, const char *name)
Lines 1394-1410 Link Here
1394
{
1393
{
1395
    KPanelApplet* init( QWidget *parent, const QString configFile )
1394
    KPanelApplet* init( QWidget *parent, const QString configFile )
1396
    {
1395
    {
1397
1396
/*
1398
        if(!Komics::lock())
1397
        if(!Komics::lock())
1399
        {
1398
        {
1400
            return 0;
1399
            return 0;
1401
        }
1400
        }
1402
        else
1401
        else
1403
        {
1402
        {*/
1404
            KGlobal::locale()->insertCatalogue("Komics");
1403
            KGlobal::locale()->insertCatalogue("Komics");
1405
            return new KomicsApplet(configFile, KPanelApplet::Normal,
1404
            return new KomicsApplet(configFile, KPanelApplet::Normal,
1406
                                    KPanelApplet::About | KPanelApplet::Preferences,
1405
                                    KPanelApplet::About | KPanelApplet::Preferences,
1407
                                    parent, "Komics");
1406
                                    parent, "Komics");
1408
        }
1407
/*        }*/
1409
    }
1408
    }
1410
}
1409
}

Return to bug 141062