From ace2dfc29e135be3acc29f8778e63eba02919510 Mon Sep 17 00:00:00 2001 From: Joao Carreira Date: Wed, 7 May 2014 14:45:23 +0100 Subject: [PATCH] Add new icons to the window menu and a new action to select the windows to be syncronized played --- resources/icons/windowscascade.png | Bin 0 -> 624 bytes resources/icons/windowstile.png | Bin 0 -> 547 bytes resources/playuver.qrc | 3 +++ source/app/plaYUVerApp.cpp | 23 +++++++++++++++++++---- source/app/plaYUVerApp.h | 2 ++ 5 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 resources/icons/windowscascade.png create mode 100644 resources/icons/windowstile.png diff --git a/resources/icons/windowscascade.png b/resources/icons/windowscascade.png new file mode 100644 index 0000000000000000000000000000000000000000..02511b783941c63f26b518944309689d61cdd4a9 GIT binary patch literal 624 zcmV-$0+0QPP)jG>HG301Z<2_xC@Be}94W z&(941etlX15I~GBb6@;-Hxg&~`HO+!=MM&kA3uTk2NZv2VE7KCzki2fWHu58sfBy| z`zMCKpLQ_-1P}`+8w3%>Ip_fB*gu)(46!kOhB#{byLbj)?&vfLQq185kVo zNRJ$lAt1y4{R4*WzyDwi;{W>jpJCq-CI)~2Vj?G1;4&1(1}OjtASQ-?|H(A;KUPB_ zd#i*e+Ga6BHG2ME@QyzVq|%M z03yo8nBn;kN7y20fB+(BFs?|#9fAKq{$l_LAiP0=OCvF<0w92Jx)@m#E|+4HgEO6n|qM5+}0R{k;%`Vnl=fmLu0000< KMNUMnLSTZbF9x~* literal 0 HcmV?d00001 diff --git a/resources/icons/windowstile.png b/resources/icons/windowstile.png new file mode 100644 index 0000000000000000000000000000000000000000..dec58e3bc44c503fc7051915e8c1e34f3cda83c3 GIT binary patch literal 547 zcmV+;0^I$HP)bmCtGvK@i4&^C!v5f=VtT z0TF!zK?!>C<|PlYPoi((Rl$oVK?oi^c=F%_c*!PQS#4fCU{`Swi`K($TR3*Vjf-{1P_!NUP{53JSNc4uqNNoRN?)-f{pH+)j zPwvq=XjiamVYN!$K(m6TNuK8oSP4$xBB<<`7R5QZuZ#NDeofngbDet!-X{+b0>qd+ z%PsRuYF2v`>{H*~6EE%$8$y7PKtkp|&;1a+7cqh)B#2IY_*7EgIe?cBuD^`eAI~^B zKH}NKInc3`gqdL`%!DLdE53a%DgS3GHi7mz5+ybbcmUNXXt#z^lYx5xy8)0!zom9*ok*1Hgg0%>>)WKzKVY*Pu^E$M3{(lO zwkW(0T|?{!JX)t!{ucDMT(+qHo-{QLpw2k}il=XW>d|3E^pO~17kwD=5V5?LqQ&8) l>vs05q1e?wuiObLZ~=c2v>+_bJO=;(002ovPDHLkV1iPO`BeY_ literal 0 HcmV?d00001 diff --git a/resources/playuver.qrc b/resources/playuver.qrc index 9ae553b..7a54937 100755 --- a/resources/playuver.qrc +++ b/resources/playuver.qrc @@ -7,6 +7,9 @@ icons/exit.png icons/configuredialog.png + icons/windowstile.png + icons/windowscascade.png + icons/zoomin.png icons/zoomout.png icons/zoomtonormal.png diff --git a/source/app/plaYUVerApp.cpp b/source/app/plaYUVerApp.cpp index 4bc934f..a8c903b 100644 --- a/source/app/plaYUVerApp.cpp +++ b/source/app/plaYUVerApp.cpp @@ -510,6 +510,11 @@ void plaYUVerApp::lockButtonEvent() } } +void plaYUVerApp::videoSelectionButtonEvent() +{ + +} + // ----------------------- Zoom Functions ----------------------- void plaYUVerApp::normalSize() @@ -540,7 +545,7 @@ void plaYUVerApp::scaleFrame( int ratio ) void plaYUVerApp::about() { QString about_message; - about_message.append("The plaYUVerApp is an open-source raw video player"); + about_message.append( "The plaYUVerApp is an open-source raw video player" ); // about_message.append("\n\r"); // about_message.append("João Carreira"); // about_message.append("\n\r"); @@ -840,11 +845,12 @@ Void plaYUVerApp::createActions() mapperSeekVideo = new QSignalMapper( this ); connect( mapperSeekVideo, SIGNAL( mapped(int) ), this, SLOT( seekEvent(int) ) ); - m_arrayActions[VIDEO_BACKWARD_ACT] = new QAction( "VideoBackward", this ); + m_arrayActions[VIDEO_BACKWARD_ACT] = new QAction( "Video Backward", this ); m_arrayActions[VIDEO_BACKWARD_ACT]->setIcon( QIcon( style()->standardIcon( QStyle::SP_MediaSeekBackward ) ) ); connect( m_arrayActions[VIDEO_BACKWARD_ACT], SIGNAL( triggered() ), mapperSeekVideo, SLOT( map() ) ); mapperSeekVideo->setMapping( m_arrayActions[VIDEO_BACKWARD_ACT], 0 ); - m_arrayActions[VIDEO_FORWARD_ACT] = new QAction( "VideoForward", this ); + + m_arrayActions[VIDEO_FORWARD_ACT] = new QAction( "Video Forward", this ); m_arrayActions[VIDEO_FORWARD_ACT]->setIcon( QIcon( style()->standardIcon( QStyle::SP_MediaSeekForward ) ) ); connect( m_arrayActions[VIDEO_FORWARD_ACT], SIGNAL( triggered() ), mapperSeekVideo, SLOT( map() ) ); mapperSeekVideo->setMapping( m_arrayActions[VIDEO_FORWARD_ACT], 1 ); @@ -853,11 +859,15 @@ Void plaYUVerApp::createActions() m_arrayActions[VIDEO_LOOP_ACT]->setCheckable( true ); m_arrayActions[VIDEO_LOOP_ACT]->setChecked( false ); - m_arrayActions[VIDEO_LOCK_ACT] = new QAction( "VideoLock", this ); + m_arrayActions[VIDEO_LOCK_ACT] = new QAction( "Video Lock", this ); m_arrayActions[VIDEO_LOCK_ACT]->setCheckable( true ); m_arrayActions[VIDEO_LOCK_ACT]->setChecked( false ); connect( m_arrayActions[VIDEO_LOCK_ACT], SIGNAL( triggered() ), this, SLOT( lockButtonEvent() ) ); + m_arrayActions[VIDEO_LOCK_SELECTION_ACT] = new QAction( "Video Lock Window Selection", this ); + m_arrayActions[VIDEO_FORWARD_ACT]->setIcon( QIcon( style()->standardIcon( QStyle::SP_MediaSeekForward ) ) ); + connect( m_arrayActions[VIDEO_LOCK_SELECTION_ACT], SIGNAL( triggered() ), this, SLOT( videoSelectionButtonEvent() ) ); + m_pcFrameSlider = new QSlider; m_pcFrameSlider->setOrientation( Qt::Horizontal ); m_pcFrameSlider->setMaximumWidth( 100 ); @@ -887,20 +897,24 @@ Void plaYUVerApp::createActions() // ------------ Window ------------ m_arrayActions[TILE_WINDOWS_ACT] = new QAction( tr( "&Tile" ), this ); + m_arrayActions[TILE_WINDOWS_ACT]->setIcon( QIcon( ":images/windowstile.png" ) ); m_arrayActions[TILE_WINDOWS_ACT]->setStatusTip( tr( "Tile the windows" ) ); connect( m_arrayActions[TILE_WINDOWS_ACT], SIGNAL( triggered() ), mdiArea, SLOT( tileSubWindows() ) ); m_arrayActions[CASCADE_WINDOWS_ACT] = new QAction( tr( "&Cascade" ), this ); + m_arrayActions[CASCADE_WINDOWS_ACT]->setIcon( QIcon( ":images/windowscascade.png" ) ); m_arrayActions[CASCADE_WINDOWS_ACT]->setStatusTip( tr( "Cascade the windows" ) ); connect( m_arrayActions[CASCADE_WINDOWS_ACT], SIGNAL( triggered() ), mdiArea, SLOT( cascadeSubWindows() ) ); m_arrayActions[NEXT_WINDOWS_ACT] = new QAction( tr( "Ne&xt" ), this ); m_arrayActions[NEXT_WINDOWS_ACT]->setShortcuts( QKeySequence::NextChild ); + m_arrayActions[NEXT_WINDOWS_ACT]->setIcon( QIcon( style()->standardIcon( QStyle::SP_ArrowRight ) ) ); m_arrayActions[NEXT_WINDOWS_ACT]->setStatusTip( tr( "Move the focus to the next window" ) ); connect( m_arrayActions[NEXT_WINDOWS_ACT], SIGNAL( triggered() ), mdiArea, SLOT( activateNextSubWindow() ) ); m_arrayActions[PREVIOUS_WINDOWS_ACT] = new QAction( tr( "Pre&vious" ), this ); m_arrayActions[PREVIOUS_WINDOWS_ACT]->setShortcuts( QKeySequence::PreviousChild ); + m_arrayActions[PREVIOUS_WINDOWS_ACT]->setIcon( QIcon( style()->standardIcon( QStyle::SP_ArrowLeft ) ) ); m_arrayActions[PREVIOUS_WINDOWS_ACT]->setStatusTip( tr( "Move the focus to the previous window" ) ); connect( m_arrayActions[PREVIOUS_WINDOWS_ACT], SIGNAL( triggered() ), mdiArea, SLOT( activatePreviousSubWindow() ) ); @@ -960,6 +974,7 @@ Void plaYUVerApp::createMenus() m_arrayMenu[VIDEO_MENU]->addAction( m_arrayActions[VIDEO_FORWARD_ACT] ); m_arrayMenu[VIDEO_MENU]->addAction( m_arrayActions[VIDEO_LOOP_ACT] ); m_arrayMenu[VIDEO_MENU]->addAction( m_arrayActions[VIDEO_LOCK_ACT] ); + m_arrayMenu[VIDEO_MENU]->addAction( m_arrayActions[VIDEO_LOCK_SELECTION_ACT] ); QMenu* modules_menu = m_pcModulesHandle->createMenus( menuBar() ); connect( modules_menu, SIGNAL( triggered(QAction *) ), this, SLOT( selectModule(QAction *) ) ); diff --git a/source/app/plaYUVerApp.h b/source/app/plaYUVerApp.h index 84fd296..f170ecf 100644 --- a/source/app/plaYUVerApp.h +++ b/source/app/plaYUVerApp.h @@ -72,6 +72,7 @@ private Q_SLOTS: void seekSliderEvent( int new_frame_num ); void seekEvent( int direction ); void lockButtonEvent(); + void videoSelectionButtonEvent(); void selectModule( QAction * ); @@ -202,6 +203,7 @@ private: VIDEO_BACKWARD_ACT, VIDEO_LOOP_ACT, VIDEO_LOCK_ACT, + VIDEO_LOCK_SELECTION_ACT, NAVIGATION_TOOL_ACT, SELECTION_TOOL_ACT, TILE_WINDOWS_ACT,