aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2002-10-25 20:53:42 (GMT)
committerfluxgen <fluxgen>2002-10-25 20:53:42 (GMT)
commit1168fcc08ac29ec2aba298a1f2d05e2c52109054 (patch)
treebef682219c1a22409af4831ba7b047c81858a47a /src
parent1cb8a2d14a0c635aa30210c301fba515f640eed3 (diff)
downloadfluxbox-1168fcc08ac29ec2aba298a1f2d05e2c52109054.zip
fluxbox-1168fcc08ac29ec2aba298a1f2d05e2c52109054.tar.bz2
changed name to Iconmenu
Diffstat (limited to 'src')
-rw-r--r--src/Icon.cc61
-rw-r--r--src/Icon.hh47
2 files changed, 0 insertions, 108 deletions
diff --git a/src/Icon.cc b/src/Icon.cc
deleted file mode 100644
index 7e3b53d..0000000
--- a/src/Icon.cc
+++ /dev/null
@@ -1,61 +0,0 @@
1// Icon.cc for Blackbox - an X11 Window manager
2// Copyright (c) 1997 - 2000 Brad Hughes (bhughes@tcac.net)
3//
4// Permission is hereby granted, free of charge, to any person obtaining a
5// copy of this software and associated documentation files (the "Software"),
6// to deal in the Software without restriction, including without limitation
7// the rights to use, copy, modify, merge, publish, distribute, sublicense,
8// and/or sell copies of the Software, and to permit persons to whom the
9// Software is furnished to do so, subject to the following conditions:
10//
11// The above copyright notice and this permission notice shall be included in
12// all copies or substantial portions of the Software.
13//
14// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE.
21
22//Use GNU extensions
23#ifndef _GNU_SOURCE
24#define _GNU_SOURCE
25#endif // _GNU_SOURCE
26
27#ifdef HAVE_CONFIG_H
28# include "../config.h"
29#endif // HAVE_CONFIG_H
30
31#include "i18n.hh"
32#include "Icon.hh"
33#include "Screen.hh"
34#include "Window.hh"
35
36
37Iconmenu::Iconmenu(BScreen *scrn) : Basemenu(scrn) {
38 setInternalMenu();
39
40 screen = scrn;
41 setLabel(I18n::instance()->getMessage(
42 FBNLS::IconSet, FBNLS::IconIcons,
43 "Icons"));
44 update();
45}
46
47
48void Iconmenu::itemSelected(int button, unsigned int index) {
49 if (button == 1) {
50 if (index < screen->getIconCount()) {
51 FluxboxWindow *win = screen->getIcon(index);
52
53 if (win)
54 win->deiconify();
55
56 }
57
58 if (! (screen->getWorkspacemenu()->isTorn() || isTorn()))
59 hide();
60 }
61}
diff --git a/src/Icon.hh b/src/Icon.hh
deleted file mode 100644
index 5d37cf1..0000000
--- a/src/Icon.hh
+++ /dev/null
@@ -1,47 +0,0 @@
1// Icon.hh for Blackbox - an X11 Window manager
2// Copyright (c) 1997 - 2000 Brad Hughes (bhughes@tcac.net)
3//
4// Permission is hereby granted, free of charge, to any person obtaining a
5// copy of this software and associated documentation files (the "Software"),
6// to deal in the Software without restriction, including without limitation
7// the rights to use, copy, modify, merge, publish, distribute, sublicense,
8// and/or sell copies of the Software, and to permit persons to whom the
9// Software is furnished to do so, subject to the following conditions:
10//
11// The above copyright notice and this permission notice shall be included in
12// all copies or substantial portions of the Software.
13//
14// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE.
21
22#ifndef ICON_HH
23#define ICON_HH
24
25// forward declaration
26class Iconmenu;
27
28class BScreen;
29
30#include "Basemenu.hh"
31
32
33class Iconmenu : public Basemenu {
34private:
35 BScreen *screen;
36
37
38protected:
39 virtual void itemSelected(int button, unsigned int index);
40
41
42public:
43 Iconmenu(BScreen *);
44};
45
46
47#endif //_ICON_HH_