diff options
| author | Eli Zaretskii | 2017-04-16 10:12:42 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2017-04-16 10:12:42 +0300 |
| commit | 1bf7ca623b3d3e02617cf0b5f8d7f980384838d3 (patch) | |
| tree | 5e6f66af64ab834a2b663f5246163ae3867491d3 /src | |
| parent | 0ef7f64407525a1e1bcc8aef4d1fd19a1cf60ec6 (diff) | |
| download | emacs-1bf7ca623b3d3e02617cf0b5f8d7f980384838d3.tar.gz emacs-1bf7ca623b3d3e02617cf0b5f8d7f980384838d3.zip | |
Avoid compilation warnings on MS-Windows
* src/w32term.c (w32_read_socket): Avoid compiler warnings about
parentheses around assignment.
* src/w32fns.c (w32_createwindow): Remove unused variable
dwStyle. Use "|=" where appropriate.
Diffstat (limited to 'src')
| -rw-r--r-- | src/w32fns.c | 15 | ||||
| -rw-r--r-- | src/w32term.c | 3 |
2 files changed, 8 insertions, 10 deletions
diff --git a/src/w32fns.c b/src/w32fns.c index 62798f269ef..8dca03265b7 100644 --- a/src/w32fns.c +++ b/src/w32fns.c | |||
| @@ -2297,7 +2297,6 @@ w32_createwindow (struct frame *f, int *coords) | |||
| 2297 | { | 2297 | { |
| 2298 | HWND hwnd = NULL, parent_hwnd = NULL; | 2298 | HWND hwnd = NULL, parent_hwnd = NULL; |
| 2299 | RECT rect; | 2299 | RECT rect; |
| 2300 | DWORD dwStyle; | ||
| 2301 | int top, left; | 2300 | int top, left; |
| 2302 | Lisp_Object border_width = Fcdr (Fassq (Qborder_width, f->param_alist)); | 2301 | Lisp_Object border_width = Fcdr (Fassq (Qborder_width, f->param_alist)); |
| 2303 | 2302 | ||
| @@ -2310,14 +2309,13 @@ w32_createwindow (struct frame *f, int *coords) | |||
| 2310 | { | 2309 | { |
| 2311 | /* If we want a thin border, specify it here. */ | 2310 | /* If we want a thin border, specify it here. */ |
| 2312 | if (NUMBERP (border_width) && (XINT (border_width) > 0)) | 2311 | if (NUMBERP (border_width) && (XINT (border_width) > 0)) |
| 2313 | f->output_data.w32->dwStyle = | 2312 | f->output_data.w32->dwStyle |= WS_BORDER; |
| 2314 | f->output_data.w32->dwStyle | WS_BORDER; | ||
| 2315 | } | 2313 | } |
| 2316 | else | 2314 | else |
| 2317 | /* To decorate a child frame, list all needed elements. */ | 2315 | /* To decorate a child frame, list all needed elements. */ |
| 2318 | f->output_data.w32->dwStyle = | 2316 | f->output_data.w32->dwStyle |= (WS_THICKFRAME | WS_CAPTION |
| 2319 | f->output_data.w32->dwStyle | WS_THICKFRAME | WS_CAPTION | 2317 | | WS_MAXIMIZEBOX | WS_MINIMIZEBOX |
| 2320 | | WS_MAXIMIZEBOX | WS_MINIMIZEBOX | WS_SYSMENU; | 2318 | | WS_SYSMENU); |
| 2321 | } | 2319 | } |
| 2322 | else if (FRAME_UNDECORATED (f)) | 2320 | else if (FRAME_UNDECORATED (f)) |
| 2323 | { | 2321 | { |
| @@ -2327,14 +2325,13 @@ w32_createwindow (struct frame *f, int *coords) | |||
| 2327 | 2325 | ||
| 2328 | /* If we want a thin border, specify it here. */ | 2326 | /* If we want a thin border, specify it here. */ |
| 2329 | if (NUMBERP (border_width) && (XINT (border_width) > 0)) | 2327 | if (NUMBERP (border_width) && (XINT (border_width) > 0)) |
| 2330 | f->output_data.w32->dwStyle = | 2328 | f->output_data.w32->dwStyle |= WS_BORDER; |
| 2331 | f->output_data.w32->dwStyle | WS_BORDER; | ||
| 2332 | } | 2329 | } |
| 2333 | else | 2330 | else |
| 2334 | f->output_data.w32->dwStyle = WS_OVERLAPPEDWINDOW; | 2331 | f->output_data.w32->dwStyle = WS_OVERLAPPEDWINDOW; |
| 2335 | 2332 | ||
| 2336 | /* Always clip children. */ | 2333 | /* Always clip children. */ |
| 2337 | f->output_data.w32->dwStyle = f->output_data.w32->dwStyle | WS_CLIPCHILDREN; | 2334 | f->output_data.w32->dwStyle |= WS_CLIPCHILDREN; |
| 2338 | 2335 | ||
| 2339 | rect.left = rect.top = 0; | 2336 | rect.left = rect.top = 0; |
| 2340 | rect.right = FRAME_PIXEL_WIDTH (f); | 2337 | rect.right = FRAME_PIXEL_WIDTH (f); |
diff --git a/src/w32term.c b/src/w32term.c index 1c3d243b62c..36dc6364ae3 100644 --- a/src/w32term.c +++ b/src/w32term.c | |||
| @@ -5136,7 +5136,8 @@ w32_read_socket (struct terminal *terminal, | |||
| 5136 | } | 5136 | } |
| 5137 | #endif | 5137 | #endif |
| 5138 | 5138 | ||
| 5139 | if (f = x_window_to_frame (dpyinfo, msg.msg.hwnd)) | 5139 | f = x_window_to_frame (dpyinfo, msg.msg.hwnd); |
| 5140 | if (f) | ||
| 5140 | x_clear_under_internal_border (f); | 5141 | x_clear_under_internal_border (f); |
| 5141 | 5142 | ||
| 5142 | check_visibility = 1; | 5143 | check_visibility = 1; |