Commit b465419f authored by YAMAMOTO Mitsuharu's avatar YAMAMOTO Mitsuharu

(mac_define_frame_cursor): Don't change pointer shape

for unfocused frame.
(x_raise_frame): Call BringToFront instead of SelectWindow.
(x_lower_frame): Use NULL instead of nil.
(x_make_frame_visible): Don't call SelectWindow.
(XTread_socket): Increment handling_signal at the start, decrement
it at the end.
[USE_CG_TEXT_DRAWING] (init_cg_text_anti_aliasing_threshold): Use
CFPreferencesGetAppIntegerValue instead of Fmac_get_preference.
parent 7d53d678
...@@ -1026,12 +1026,15 @@ static int cg_text_anti_aliasing_threshold = 8; ...@@ -1026,12 +1026,15 @@ static int cg_text_anti_aliasing_threshold = 8;
static void static void
init_cg_text_anti_aliasing_threshold () init_cg_text_anti_aliasing_threshold ()
{ {
Lisp_Object val = int threshold;
Fmac_get_preference (build_string ("AppleAntiAliasingThreshold"), Boolean valid_p;
Qnil, Qnil, Qnil);
if (INTEGERP (val)) threshold =
cg_text_anti_aliasing_threshold = XINT (val); CFPreferencesGetAppIntegerValue (CFSTR ("AppleAntiAliasingThreshold"),
kCFPreferencesCurrentApplication,
&valid_p);
if (valid_p)
cg_text_anti_aliasing_threshold = threshold;
} }
static int static int
...@@ -5299,7 +5302,10 @@ mac_define_frame_cursor (f, cursor) ...@@ -5299,7 +5302,10 @@ mac_define_frame_cursor (f, cursor)
struct frame *f; struct frame *f;
Cursor cursor; Cursor cursor;
{ {
SetThemeCursor (cursor); struct mac_display_info *dpyinfo = FRAME_MAC_DISPLAY_INFO (f);
if (dpyinfo->x_focus_frame == f)
SetThemeCursor (cursor);
} }
...@@ -5837,7 +5843,7 @@ x_raise_frame (f) ...@@ -5837,7 +5843,7 @@ x_raise_frame (f)
if (f->async_visible) if (f->async_visible)
{ {
BLOCK_INPUT; BLOCK_INPUT;
SelectWindow (FRAME_MAC_WINDOW (f)); BringToFront (FRAME_MAC_WINDOW (f));
UNBLOCK_INPUT; UNBLOCK_INPUT;
} }
} }
...@@ -5851,7 +5857,7 @@ x_lower_frame (f) ...@@ -5851,7 +5857,7 @@ x_lower_frame (f)
if (f->async_visible) if (f->async_visible)
{ {
BLOCK_INPUT; BLOCK_INPUT;
SendBehind (FRAME_MAC_WINDOW (f), nil); SendBehind (FRAME_MAC_WINDOW (f), NULL);
UNBLOCK_INPUT; UNBLOCK_INPUT;
} }
} }
...@@ -5964,7 +5970,6 @@ x_make_frame_visible (f) ...@@ -5964,7 +5970,6 @@ x_make_frame_visible (f)
f->output_data.mac->asked_for_visible = 1; f->output_data.mac->asked_for_visible = 1;
SelectWindow (FRAME_MAC_WINDOW (f));
CollapseWindow (FRAME_MAC_WINDOW (f), false); CollapseWindow (FRAME_MAC_WINDOW (f), false);
ShowWindow (FRAME_MAC_WINDOW (f)); ShowWindow (FRAME_MAC_WINDOW (f));
} }
...@@ -9581,6 +9586,8 @@ XTread_socket (sd, expected, hold_quit) ...@@ -9581,6 +9586,8 @@ XTread_socket (sd, expected, hold_quit)
/* So people can tell when we have read the available input. */ /* So people can tell when we have read the available input. */
input_signal_count++; input_signal_count++;
++handling_signal;
#if USE_CARBON_EVENTS #if USE_CARBON_EVENTS
toolbox_dispatcher = GetEventDispatcherTarget (); toolbox_dispatcher = GetEventDispatcherTarget ();
...@@ -10221,6 +10228,7 @@ XTread_socket (sd, expected, hold_quit) ...@@ -10221,6 +10228,7 @@ XTread_socket (sd, expected, hold_quit)
} }
#endif #endif
--handling_signal;
UNBLOCK_INPUT; UNBLOCK_INPUT;
return count; return count;
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment