Commit df3bb4bf authored by Scott Wheeler's avatar Scott Wheeler

When the user attempts to start a new instance of JuK, show the running

instance.

svn path=/trunk/kdemultimedia/juk/; revision=214903
parent 4a75e0bb
......@@ -29,6 +29,19 @@ static const char *tim = I18N_NOOP("GStreamer port");
static const char *stefan = I18N_NOOP("Global keybindings support");
static const char *stephan = I18N_NOOP("Track announcement popups");
class Application : public KUniqueApplication
{
public:
Application() : KUniqueApplication(true, true, false) {}
virtual ~Application() {}
virtual int newInstance() {
QWidget *w = mainWidget();
if(w)
w->setShown(true);
return KUniqueApplication::newInstance();
}
};
static KCmdLineOptions options[] =
{
{ "+[file(s)]", I18N_NOOP("File(s) to open"), 0 },
......@@ -50,7 +63,7 @@ int main(int argc, char *argv[])
KCmdLineArgs::init(argc, argv, &aboutData);
KCmdLineArgs::addCmdLineOptions(options);
KUniqueApplication a;
Application a;
JuK *juk = new JuK();
a.setMainWidget(juk);
juk->show();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment