From: konrad Date: Sun, 8 Jul 2007 14:38:59 +0000 (+0000) Subject: not much more X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=a00b537ba96d1d0b1377b655d2de58f440ef2931;p=konrad%2Fsmoke.git not much more git-svn-id: https://silmor.de/svn/softmagic/smoke/trunk@10 6e3c4bff-ac9f-4ac1-96c5-d2ea494d3e33 --- diff --git a/src/main.cpp b/src/main.cpp index 832005f..c03dbc7 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -14,6 +14,8 @@ #include #include #include +#include +#include #include "keygen.h" #include "mainwindow.h" @@ -41,8 +43,19 @@ int main(int argc,char**argv) MKeyGen mkg; if(mkg.exec()==QDialog::Accepted) QSettings().setValue("hostkey",mkg.getKey()); + else{ + QMessageBox::critical(0,app.translate("initkey","Warning"), app.translate("initkey","Magic Smoke needs a host key. You have to generate one before you can use the program.")); + return 1; + } } - if(!QSettings().contains("profiles")){ + QString iprof; + if(!QSettings().childGroups().contains("profiles")){ + iprof="0"; + bool ok; + QString ipname=app.translate("initprofile","default","initial profile"); + ipname=QInputDialog::getText(0,app.translate("initprofile","Create Initial Profile"), app.translate("initprofile","You need a profile to work with Magic Smoke. Magic Smoke will now create one for you. Please enter the name you wish to give this profile."), QLineEdit::Normal, ipname, &ok); + if(!ok || ipname.isEmpty())return 1; + QSettings().setValue("profiles/0/name",ipname); } MMainWindow mmw; diff --git a/src/smoke_de.ts b/src/smoke_de.ts index 4f562b9..c2c30a8 100644 --- a/src/smoke_de.ts +++ b/src/smoke_de.ts @@ -30,4 +30,36 @@ At least %1 Bits of random are required. &Abbrechen + + initkey + + + Warning + + + + + Magic Smoke needs a host key. You have to generate one before you can use the program. + + + + + initprofile + + + default + initial profile + + + + + Create Initial Profile + + + + + You need a profile to work with Magic Smoke. Magic Smoke will now create one for you. Please enter the name you wish to give this profile. + + + diff --git a/src/smoke_de_SAX.ts b/src/smoke_de_SAX.ts index abb570d..b7a2704 100644 --- a/src/smoke_de_SAX.ts +++ b/src/smoke_de_SAX.ts @@ -31,4 +31,36 @@ At least %1 Bits of random are required. &Nee lass mal. + + initkey + + + Warning + Dumm gelaufen + + + + Magic Smoke needs a host key. You have to generate one before you can use the program. + Mädschig Schmohg brauchd 'nen Schlüssel. Desweschen isser beleidschd. Beim nächsden Schdard mussde ihn einen mach'n lass'n. + + + + initprofile + + + default + initial profile + Schandardbrofiel + + + + Create Initial Profile + Erschdes Brofiel anlechen + + + + You need a profile to work with Magic Smoke. Magic Smoke will now create one for you. Please enter the name you wish to give this profile. + Gugge, Du brauchsd sowas wie'n Brofiel. Mädschig Schmohg iss nedd und machd eens für Disch. Desderweschen brauchsde jedsd nur noch n Namen dafür eindibben. + +