Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
ac865ad9
Commit
ac865ad9
authored
Sep 17, 2008
by
Paul Chitescu
Committed by
Alexandre Julliard
Sep 17, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
explorer: WM_SYSCOMMAND SC_SCREENSAVE to desktop triggers screen saver.
parent
da012ed8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
1 deletion
+26
-1
desktop.c
programs/explorer/desktop.c
+26
-1
No files found.
programs/explorer/desktop.c
View file @
ac865ad9
...
...
@@ -18,6 +18,8 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "config.h"
#include "wine/port.h"
#include <stdio.h>
#include "wine/unicode.h"
...
...
@@ -34,6 +36,22 @@ WINE_DEFAULT_DEBUG_CHANNEL(explorer);
static
BOOL
using_root
;
/* screen saver handler */
static
BOOL
start_screensaver
(
void
)
{
if
(
using_root
)
{
const
char
*
argv
[
3
]
=
{
"xdg-screensaver"
,
"activate"
,
NULL
};
int
pid
=
spawnvp
(
_P_NOWAIT
,
argv
[
0
],
argv
);
if
(
pid
>
0
)
{
WINE_TRACE
(
"started process %d
\n
"
,
pid
);
return
TRUE
;
}
}
return
FALSE
;
}
/* window procedure for the desktop window */
static
LRESULT
WINAPI
desktop_wnd_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wp
,
LPARAM
lp
)
{
...
...
@@ -42,7 +60,14 @@ static LRESULT WINAPI desktop_wnd_proc( HWND hwnd, UINT message, WPARAM wp, LPAR
switch
(
message
)
{
case
WM_SYSCOMMAND
:
if
((
wp
&
0xfff0
)
==
SC_CLOSE
)
ExitWindows
(
0
,
0
);
switch
(
wp
&
0xfff0
)
{
case
SC_CLOSE
:
ExitWindows
(
0
,
0
);
break
;
case
SC_SCREENSAVE
:
return
start_screensaver
();
}
return
0
;
case
WM_CLOSE
:
...
...
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