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
c255bf46
Commit
c255bf46
authored
Jan 11, 2007
by
Francois Gouget
Committed by
Alexandre Julliard
Jan 12, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
xrandr: Small X11DRV_XRandR_(Get|Set)CurrentMode() code optimisations.
parent
d99f9ab7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
xrandr.c
dlls/winex11.drv/xrandr.c
+5
-2
No files found.
dlls/winex11.drv/xrandr.c
View file @
c255bf46
...
...
@@ -162,6 +162,8 @@ static int X11DRV_XRandR_GetCurrentMode(void)
sc
=
pXRRGetScreenInfo
(
gdi_display
,
root
);
size
=
pXRRConfigCurrentConfiguration
(
sc
,
&
rot
);
rate
=
pXRRConfigCurrentRate
(
sc
);
pXRRFreeScreenConfigInfo
(
sc
);
wine_tsx11_unlock
();
for
(
i
=
0
;
i
<
real_xrandr_modes_count
;
i
++
)
{
if
(
(
dd_modes
[
i
].
dwWidth
==
real_xrandr_sizes
[
size
].
width
)
&&
...
...
@@ -169,10 +171,9 @@ static int X11DRV_XRandR_GetCurrentMode(void)
(
dd_modes
[
i
].
wRefreshRate
==
rate
)
)
{
res
=
i
;
break
;
}
}
pXRRFreeScreenConfigInfo
(
sc
);
wine_tsx11_unlock
();
if
(
res
==
-
1
)
{
ERR
(
"In unknown mode, returning default
\n
"
);
...
...
@@ -226,6 +227,7 @@ static void X11DRV_XRandR_SetCurrentMode(int mode)
dd_modes
[
mode
].
dwWidth
,
dd_modes
[
mode
].
dwHeight
,
rate
);
stat
=
pXRRSetScreenConfigAndRate
(
gdi_display
,
sc
,
root
,
size
,
rot
,
rate
,
CurrentTime
);
break
;
}
}
}
...
...
@@ -235,6 +237,7 @@ static void X11DRV_XRandR_SetCurrentMode(int mode)
dd_modes
[
mode
].
dwWidth
,
dd_modes
[
mode
].
dwHeight
);
stat
=
pXRRSetScreenConfig
(
gdi_display
,
sc
,
root
,
size
,
rot
,
CurrentTime
);
}
break
;
}
}
pXRRFreeScreenConfigInfo
(
sc
);
...
...
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