aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog9
-rw-r--r--src/frame.c13
-rw-r--r--src/gtkutil.c9
-rw-r--r--src/xfns.c2
4 files changed, 15 insertions, 18 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 66e7bfb9d0f..56f88f5bec4 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,12 @@
12015-02-08 Paul Eggert <eggert@cs.ucla.edu>
2
3 Minor tweaks to frame_size_history_add
4 * frame.c (frame_size_history_add): Don't assume length fits in 'int'.
5 Prefer XCAR and XCDR to Fcar and Fcdr when the arg is a cons.
6 (Fframe_after_make_frame): Simplify.
7 * gtkutil.c: Remove commented-out code.
8 * xfns.c (Fx_create_frame): Fix indenting.
9
12015-02-08 Eli Zaretskii <eliz@gnu.org> 102015-02-08 Eli Zaretskii <eliz@gnu.org>
2 11
3 * frame.c (Fframe_parameter): Don't replace a non-nil value of 12 * frame.c (Fframe_parameter): Don't replace a non-nil value of
diff --git a/src/frame.c b/src/frame.c
index 9060f569154..92b6b7c73ba 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -155,14 +155,13 @@ frame_size_history_add (struct frame *f, Lisp_Object fun_symbol,
155 int width, int height, Lisp_Object rest) 155 int width, int height, Lisp_Object rest)
156{ 156{
157 Lisp_Object frame; 157 Lisp_Object frame;
158 int number;
159 158
160 XSETFRAME (frame, f); 159 XSETFRAME (frame, f);
161 if (CONSP (frame_size_history) 160 if (CONSP (frame_size_history)
162 && NUMBERP (Fcar (frame_size_history)) 161 && INTEGERP (XCAR (frame_size_history))
163 && ((number = XINT (Fcar (frame_size_history))) > 0)) 162 && 0 < XINT (XCAR (frame_size_history)))
164 frame_size_history = 163 frame_size_history =
165 Fcons (make_number (number - 1), 164 Fcons (make_number (XINT (XCAR (frame_size_history)) - 1),
166 Fcons (list4 165 Fcons (list4
167 (frame, fun_symbol, 166 (frame, fun_symbol,
168 ((width > 0) 167 ((width > 0)
@@ -172,7 +171,7 @@ frame_size_history_add (struct frame *f, Lisp_Object fun_symbol,
172 make_number (height)) 171 make_number (height))
173 : Qnil), 172 : Qnil),
174 rest), 173 rest),
175 Fcdr (frame_size_history))); 174 XCDR (frame_size_history)));
176} 175}
177 176
178 177
@@ -2298,9 +2297,7 @@ otherwise used with utter care to avoid that running functions on
2298 (Lisp_Object frame, Lisp_Object made) 2297 (Lisp_Object frame, Lisp_Object made)
2299{ 2298{
2300 struct frame *f = decode_live_frame (frame); 2299 struct frame *f = decode_live_frame (frame);
2301 2300 f->after_make_frame = !NILP (made);
2302 f->after_make_frame = NILP (made) ? false : true;
2303
2304 return made; 2301 return made;
2305} 2302}
2306 2303
diff --git a/src/gtkutil.c b/src/gtkutil.c
index 063e88262d9..6f1707894c1 100644
--- a/src/gtkutil.c
+++ b/src/gtkutil.c
@@ -50,12 +50,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
50#include "emacsgtkfixed.h" 50#include "emacsgtkfixed.h"
51#endif 51#endif
52 52
53/** #define FRAME_TOTAL_PIXEL_HEIGHT(f) \ **/
54/** (FRAME_PIXEL_HEIGHT (f) + FRAME_MENUBAR_HEIGHT (f) + FRAME_TOOLBAR_HEIGHT (f)) **/
55
56/** #define FRAME_TOTAL_PIXEL_WIDTH(f) \ **/
57/** (FRAME_PIXEL_WIDTH (f) + FRAME_TOOLBAR_WIDTH (f)) **/
58
59#ifndef HAVE_GTK_WIDGET_SET_HAS_WINDOW 53#ifndef HAVE_GTK_WIDGET_SET_HAS_WINDOW
60#define gtk_widget_set_has_window(w, b) \ 54#define gtk_widget_set_has_window(w, b) \
61 (gtk_fixed_set_has_window (GTK_FIXED (w), b)) 55 (gtk_fixed_set_has_window (GTK_FIXED (w), b))
@@ -903,9 +897,6 @@ xg_frame_resized (struct frame *f, int pixelwidth, int pixelheight)
903 || pixelwidth != FRAME_PIXEL_WIDTH (f) 897 || pixelwidth != FRAME_PIXEL_WIDTH (f)
904 || pixelheight != FRAME_PIXEL_HEIGHT (f)) 898 || pixelheight != FRAME_PIXEL_HEIGHT (f))
905 { 899 {
906/** FRAME_PIXEL_WIDTH (f) = pixelwidth; **/
907/** FRAME_PIXEL_HEIGHT (f) = pixelheight; **/
908
909 xg_clear_under_internal_border (f); 900 xg_clear_under_internal_border (f);
910 change_frame_size (f, width, height, 0, 1, 0, 1); 901 change_frame_size (f, width, height, 0, 1, 0, 1);
911 SET_FRAME_GARBAGED (f); 902 SET_FRAME_GARBAGED (f);
diff --git a/src/xfns.c b/src/xfns.c
index e667e71b563..629ac4b26ff 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -3184,7 +3184,7 @@ This function is an internal primitive--use `make-frame' instead. */)
3184 "title", "Title", RES_TYPE_STRING); 3184 "title", "Title", RES_TYPE_STRING);
3185 x_default_parameter (f, parms, Qwait_for_wm, Qt, 3185 x_default_parameter (f, parms, Qwait_for_wm, Qt,
3186 "waitForWM", "WaitForWM", RES_TYPE_BOOLEAN); 3186 "waitForWM", "WaitForWM", RES_TYPE_BOOLEAN);
3187 x_default_parameter (f, parms, Qtool_bar_position, 3187 x_default_parameter (f, parms, Qtool_bar_position,
3188 FRAME_TOOL_BAR_POSITION (f), 0, 0, RES_TYPE_SYMBOL); 3188 FRAME_TOOL_BAR_POSITION (f), 0, 0, RES_TYPE_SYMBOL);
3189 3189
3190 /* Compute the size of the X window. */ 3190 /* Compute the size of the X window. */