all repos — fluxbox @ 3598527d190af3e1f0874b6fc47fed86e19faac4

custom fork of the fluxbox windowmanager

we can now use the same action strings in the menu as in key actions
fluxgen fluxgen
commit

3598527d190af3e1f0874b6fc47fed86e19faac4

parent

a4cffd7ec48ac26ae733906948114ea3453ddd1c

1 files changed, 10 insertions(+), 2 deletions(-)

jump to
M src/Screen.ccsrc/Screen.cc

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Screen.cc,v 1.196 2003/06/27 15:05:19 rathnor Exp $ +// $Id: Screen.cc,v 1.197 2003/06/30 15:31:54 fluxgen Exp $ #include "Screen.hh"

@@ -55,6 +55,7 @@ #include "FbWinFrame.hh"

#include "FbWindow.hh" #include "Strut.hh" #include "SlitTheme.hh" +#include "CommandParser.hh" //use GNU extensions #ifndef _GNU_SOURCE

@@ -1926,7 +1927,14 @@ "no menu label defined\n"));

cerr<<"Row: "<<row<<endl; } else menu.insert(str_label.c_str(), workspacemenu.get()); - } // end of work + } // end of workspaces + else { // ok, if we didn't find any special menu item we try with command parser + // we need to attach command with arguments so command parser can parse it + string line = str_key + " " + str_cmd; + FbTk::RefCount<FbTk::Command> command(CommandParser::instance().parseLine(line)); + if (*command != 0) + menu.insert(str_label.c_str(), command); + } } } }