From 646182be7176ec52f3d69b94d7c552b1496171b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Wed, 27 Sep 2006 18:00:35 +0000 Subject: [PATCH] * When specifying invalid arguments, an error message is now printed. This fixes bug #714. * Removed some useless information. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18950 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/workspaces/Workspaces.cpp | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/src/apps/workspaces/Workspaces.cpp b/src/apps/workspaces/Workspaces.cpp index 8c2d846813..dac07a6b36 100644 --- a/src/apps/workspaces/Workspaces.cpp +++ b/src/apps/workspaces/Workspaces.cpp @@ -10,12 +10,10 @@ * Matt Madia */ -/** Workspaces window trick found by Michael "Minox" Paine. - * (using B_ALL_WORKSPACES as flags in BWindow) - * Found out that using 0xffffffff as Flags was causing the window not to close on Alt-W - * hey Workspaces get Flags of Window 0 - * gives 0x00008080 which makes it. - */ +/*! + Workspaces window trick found by Michael "Minox" Paine. + (using B_ALL_WORKSPACES as flags in BWindow) +*/ #include @@ -358,6 +356,12 @@ WorkspacesApp::ArgvReceived(int32 argc, char **argv) // if the app is running, don't quit // but if it isn't, cancel the complete run, so it doesn't // open any window + if (IsLaunching()) + Quit(); + } else { + // some unknown arguments were specified + fprintf(stderr, "Invalid argument: %s\n", argv[i]); + if (IsLaunching()) Quit(); }