TWin, Kicker: Add icons for tiling menus

Signed-off-by: Mavridis Philippe <mavridisf@gmail.com>
pull/522/head
Mavridis Philippe 3 months ago
parent 4cd5817775
commit 66ebe21d5e
No known key found for this signature in database
GPG Key ID: F8D2D7E2F989A494

@ -24,6 +24,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include <assert.h>
#include <tdeglobal.h>
#include <kiconloader.h>
#include <tdelocale.h>
@ -44,6 +45,8 @@ TaskRMBMenu::TaskRMBMenu(const Task::List& theTasks, bool show, TQPopupMenu* mov
, showAll( show )
, taskMoveMenu( moveMenu )
{
TDEGlobal::iconLoader()->addAppDir("twin");
assert(tasks.count() > 0);
if (tasks.count() == 1)
{
@ -290,23 +293,23 @@ TQPopupMenu* TaskRMBMenu::makeTileMenu(Task::Ptr t)
TQPopupMenu *m = new TQPopupMenu( this );
// Tile to side (the menu id matched the ActiveBorder index used for tiling)
int id = m->insertItem( i18n("&Left"), this, TQ_SLOT( slotTileTo(int) ) );
int id = m->insertItem( UserIconSet("tile_left"), i18n("&Left"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 6 );
id = m->insertItem( i18n("&Right"), this, TQ_SLOT( slotTileTo(int) ) );
id = m->insertItem( UserIconSet("tile_right"), i18n("&Right"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 2 );
id = m->insertItem( i18n("&Top"), this, TQ_SLOT( slotTileTo(int) ) );
id = m->insertItem( UserIconSet("tile_top"), i18n("&Top"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 0 );
id = m->insertItem( i18n("&Bottom"), this, TQ_SLOT( slotTileTo(int) ) );
id = m->insertItem( UserIconSet("tile_bottom"), i18n("&Bottom"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 4 );
// Tile to corner (the menu id matched the ActiveBorder index used for tiling)
id = m->insertItem( i18n("Top &Left"), this, TQ_SLOT( slotTileTo(int) ) );
id = m->insertItem( UserIconSet("tile_topleft"), i18n("Top &Left"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 7 );
id = m->insertItem( i18n("Top &Right"), this, TQ_SLOT( slotTileTo(int) ) );
id = m->insertItem( UserIconSet("tile_topright"), i18n("Top &Right"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 1 );
id = m->insertItem( i18n("Bottom L&eft"), this, TQ_SLOT( slotTileTo(int) ) );
id = m->insertItem( UserIconSet("tile_bottomleft"), i18n("Bottom L&eft"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 5 );
id = m->insertItem( i18n("&Bottom R&ight"), this, TQ_SLOT( slotTileTo(int) ) );
id = m->insertItem( UserIconSet("tile_bottomright"), i18n("&Bottom R&ight"), this, TQ_SLOT( slotTileTo(int) ) );
m->setItemParameter( id, 3 );
return m;

@ -15,7 +15,6 @@ add_subdirectory( lib )
add_subdirectory( killer )
add_subdirectory( resumer )
add_subdirectory( kcmtwin )
add_subdirectory( pics )
add_subdirectory( clients )
add_subdirectory( oldheaders )
add_subdirectory( data )
@ -40,10 +39,18 @@ link_directories(
install( FILES KWinInterface.h DESTINATION ${INCLUDE_INSTALL_DIR} )
##### other data ################################
##### icons #####################################
tde_install_icons( twin )
install(
DIRECTORY pics/
DESTINATION ${DATA_INSTALL_DIR}/twin/pics
FILES_MATCHING PATTERN *.png
)
##### other data ################################
tde_create_translated_desktop(
SOURCE eventsrc
DESTINATION ${DATA_INSTALL_DIR}/twin

@ -1,16 +0,0 @@
#################################################
#
# (C) 2010-2011 Serghei Amelian
# serghei (DOT) amelian (AT) gmail.com
#
# Improvements and feedback are welcome
#
# This file is released under GPL >= 2
#
#################################################
install( FILES
close.png maximize.png maximizedown.png menu.png
iconify.png pindown.png pinup.png unknown.png fog.png
fog-grey.png bluesun.png greenie.light.png greenie.dim.png
DESTINATION ${DATA_INSTALL_DIR}/twin/pics )

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

@ -49,23 +49,23 @@ TQPopupMenu* Workspace::makeTileMenu()
TQPopupMenu *m = new TQPopupMenu;
// Tile to side (the menu id matched the ActiveBorder index used for tiling)
int id = m->insertItem( i18n("&Left"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
int id = m->insertItem( SmallIconSet("tile_left"), i18n("&Left"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 6 );
id = m->insertItem( i18n("&Right"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
id = m->insertItem( SmallIconSet("tile_right"), i18n("&Right"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 2 );
id = m->insertItem( i18n("&Top"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
id = m->insertItem( SmallIconSet("tile_top"), i18n("&Top"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 0 );
id = m->insertItem( i18n("&Bottom"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
id = m->insertItem( SmallIconSet("tile_bottom"), i18n("&Bottom"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 4 );
// Tile to corner (the menu id matched the ActiveBorder index used for tiling)
id = m->insertItem( i18n("Top &Left"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
id = m->insertItem( SmallIconSet("tile_topleft"), i18n("Top &Left"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 7 );
id = m->insertItem( i18n("Top &Right"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
id = m->insertItem( SmallIconSet("tile_topright"), i18n("Top &Right"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 1 );
id = m->insertItem( i18n("Bottom L&eft"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
id = m->insertItem( SmallIconSet("tile_bottomleft"), i18n("Bottom L&eft"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 5 );
id = m->insertItem( i18n("&Bottom R&ight"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
id = m->insertItem( SmallIconSet("tile_bottomright"), i18n("&Bottom R&ight"), this, TQ_SLOT( tileCurrentWindowToBorder(int) ) );
m->setItemParameter( id, 3 );
return m;

Loading…
Cancel
Save