Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-1.1
Commits
dfab7288
Commit
dfab7288
authored
Mar 14, 2005
by
Anil Daoud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* wxwindows/*: disable systray code for wx2.4 (Thanks Gildas)
parent
5ff0a308
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
4 deletions
+20
-4
modules/gui/wxwindows/interface.cpp
modules/gui/wxwindows/interface.cpp
+14
-3
modules/gui/wxwindows/wxwindows.cpp
modules/gui/wxwindows/wxwindows.cpp
+2
-0
modules/gui/wxwindows/wxwindows.h
modules/gui/wxwindows/wxwindows.h
+4
-1
No files found.
modules/gui/wxwindows/interface.cpp
View file @
dfab7288
...
...
@@ -50,7 +50,9 @@
/* include the icon graphic */
#include "../../../share/vlc32x32.xpm"
/* include a small icon graphic for the systray icon */
#ifdef wxHAS_TASK_BAR_ICON
#include "../../../share/vlc16x16.xpm"
#endif
/*****************************************************************************
* Local class declarations.
...
...
@@ -100,6 +102,7 @@ BEGIN_EVENT_TABLE(wxVolCtrl, wxWindow)
END_EVENT_TABLE
()
/* Systray integration */
#ifdef wxHAS_TASK_BAR_ICON
class
Systray
:
public
wxTaskBarIcon
{
public:
...
...
@@ -117,7 +120,7 @@ private:
Interface
*
p_main_interface
;
DECLARE_EVENT_TABLE
()
};
#endif
/*****************************************************************************
* Event Table.
...
...
@@ -225,6 +228,7 @@ BEGIN_EVENT_TABLE(Interface, wxFrame)
END_EVENT_TABLE
()
#ifdef wxHAS_TASK_BAR_ICON
BEGIN_EVENT_TABLE
(
Systray
,
wxTaskBarIcon
)
/* Mouse events */
EVT_TASKBAR_LEFT_DOWN
(
Systray
::
OnLeftClick
)
...
...
@@ -236,6 +240,7 @@ BEGIN_EVENT_TABLE(Systray, wxTaskBarIcon)
EVT_MENU
(
PrevStream_Event
,
Systray
::
OnPrevStream
)
EVT_MENU
(
StopStream_Event
,
Systray
::
OnStopStream
)
END_EVENT_TABLE
()
#endif
/*****************************************************************************
* Constructor.
...
...
@@ -253,7 +258,7 @@ Interface::Interface( intf_thread_t *_p_intf, long style ):
extra_window
=
NULL
;
/* Give our interface a nice little icon */
SetIcon
(
wxIcon
(
vlc
16x16
_xpm
)
);
SetIcon
(
wxIcon
(
vlc_xpm
)
);
/* Create a sizer for the main frame */
frame_sizer
=
new
wxBoxSizer
(
wxVERTICAL
);
...
...
@@ -265,17 +270,19 @@ Interface::Interface( intf_thread_t *_p_intf, long style ):
p_dummy
->
SetFocus
();
frame_sizer
->
Add
(
p_dummy
,
0
,
0
);
#ifdef wxHAS_TASK_BAR_ICON
/* Systray integration */
p_systray
=
NULL
;
if
(
config_GetInt
(
p_intf
,
"wxwin-systray"
)
)
{
p_systray
=
new
Systray
(
this
);
p_systray
->
SetIcon
(
wxIcon
(
vlc_xpm
),
wxT
(
"VLC media player"
)
);
p_systray
->
SetIcon
(
wxIcon
(
vlc
16x16
_xpm
),
wxT
(
"VLC media player"
)
);
if
(
(
!
p_systray
->
IsOk
())
||
(
!
p_systray
->
IsIconInstalled
())
)
{
msg_Warn
(
p_intf
,
"Cannot set systray icon, weird things may happen"
);
}
}
#endif
/* Creation of the menu bar */
CreateOurMenuBar
();
...
...
@@ -328,10 +335,12 @@ Interface::Interface( intf_thread_t *_p_intf, long style ):
Interface
::~
Interface
()
{
#ifdef wxHAS_TASK_BAR_ICON
if
(
p_systray
)
{
delete
p_systray
;
}
#endif
if
(
p_intf
->
p_sys
->
p_wxwindow
)
{
...
...
@@ -1299,6 +1308,7 @@ void wxVolCtrl::UpdateVolume()
* Definition of Systray class.
*****************************************************************************/
#ifdef wxHAS_TASK_BAR_ICON
Systray
::
Systray
(
Interface
*
_p_main_interface
)
{
p_main_interface
=
_p_main_interface
;
...
...
@@ -1349,4 +1359,5 @@ wxMenu* Systray::CreatePopupMenu()
systray_menu
->
Append
(
Iconize_Event
,
wxU
(
_
(
"Show/Hide interface"
))
);
return
systray_menu
;
}
#endif
modules/gui/wxwindows/wxwindows.cpp
View file @
dfab7288
...
...
@@ -117,8 +117,10 @@ vlc_module_begin();
BOOKMARKS_TEXT
,
BOOKMARKS_LONGTEXT
,
VLC_FALSE
);
add_bool
(
"wxwin-taskbar"
,
1
,
NULL
,
TASKBAR_TEXT
,
TASKBAR_LONGTEXT
,
VLC_FALSE
);
#ifdef wxHAS_TASK_BAR_ICON
add_bool
(
"wxwin-systray"
,
0
,
NULL
,
SYSTRAY_TEXT
,
SYSTRAY_LONGTEXT
,
VLC_FALSE
);
#endif
add_submodule
();
set_description
(
_
(
"wxWindows dialogs provider"
)
);
...
...
modules/gui/wxwindows/wxwindows.h
View file @
dfab7288
...
...
@@ -45,7 +45,6 @@
#include <wx/taskbar.h>
#include "vlc_keys.h"
/* Hmmm, work-around for newest wxWin */
#ifdef wxStaticCastEvent
# undef wxStaticCastEvent
...
...
@@ -94,7 +93,9 @@ class DialogsProvider;
class
PrefsTreeCtrl
;
class
AutoBuiltPanel
;
class
VideoWindow
;
#ifdef wxHAS_TASK_BAR_ICON
class
Systray
;
#endif
/*****************************************************************************
* intf_sys_t: description and status of wxwindows interface
...
...
@@ -321,7 +322,9 @@ public:
vlc_bool_t
b_undock
;
wxGauge
*
volctrl
;
#ifdef wxHAS_TASK_BAR_ICON
Systray
*
p_systray
;
#endif
private:
void
SetupHotkeys
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment