Commit Graph

690 Commits

Author SHA1 Message Date
Ek Kato
08042ea830 Bug 705750 Quartz input method doesn't work correctly for Chinese characters
Modified from original for Gtk3.
2013-08-16 11:18:29 -07:00
Ek Kato
40c429c2cb Bug 705181 Annoying beep on arrow keys
Original patch was a bit excessive, just needed to not forward the command.
2013-08-13 11:16:03 -07:00
John Ralls
dfbd0c2b98 Implement gdk_display_get_cursor_for_surface in quartz
Left out of b2113b7, breaking quartz build
2013-08-11 10:43:48 -07:00
John Ralls
31c2e95cbd Bug 701571 NSApp doesn't notice NSWindow destruction
Part 1 of the fix; part 2 awaits Glib developer approval (see
https://bugzilla.gnome.org/show_bug.cgi?id=704374) and is more
correctly associated with
https://bugzilla.gnome.org/show_bug.cgi?id=674108
2013-08-11 10:43:47 -07:00
Daniel Sabo
a1955e8d88 Reset cursor when mouse leaves a toplevel window.
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=692548
2013-08-08 09:38:09 -05:00
Alexander Larsson
71fe43543c gdk: Add gdk_cursor_get_surface()
We want a surface so we can properly represent the scale factor for it.
All backends are converted to use surfaces and we reimplement the
backwards compat code in the generic code.
2013-08-07 13:34:10 +02:00
Michael Hutchinson
a78643bd6f Bug 705181: Fix annoying beeping introduced by Mac IME
NSTextInputClient should not chain unhandled commands to super

(cherry picked from commit 91bcca6f39)
2013-07-30 17:27:10 -07:00
Ek Kato
fbfce31889 Bug 701332 - Patch for minor glitch in NSTextInput
(cherry picked from commit 43ed68aa33)
2013-07-27 14:09:55 -07:00
William Hua
947385ebae Bug 704216: Fix prototype for gdk_quartz_device_core_warp. 2013-07-15 10:18:22 -07:00
Alexander Larsson
e8b38fedbd gdk: Convert mouse position to doubles, add new getters
We've long had double precision mouse coordinates on wayland (e.g.
when rotating a window) but with the new scaling we even have it on
X (and, its also in Xinput2), so convert all the internal mouse/device
position getters to use doubles and add new accessors for the
public APIs that take doubles instead of ints.
2013-07-03 14:39:25 +02:00
Michael Natterer
d4607be003 quartz: Implement get_scale_factor() on screen and window 2013-07-03 14:34:13 +02:00
Alexander Larsson
aa3f0f8ec9 quartz: Remove unused functions
The _gdk_windowing_* stuff is not used anymore
2013-07-03 12:27:10 +02:00
Michael Natterer
e5e17cf361 quartz: remove check for keymap changes from update_keymap()
The function is now only called when the keymap has actually
changed. bug #698183.
(cherry picked from commit e62709da2e)
2013-06-20 17:27:24 +02:00
Michael Natterer
bbe3554fa9 quartz: update the keymap only if the input method changed
and not on each keystroke, which for some IMs apparently caused a full
update on each keystroke, not just a check for changes. Patch from
Takuro Ashie, bug #698183.
2013-06-20 17:09:37 +02:00
Michael Natterer
4c896c9025 quartz: move dialogs to the same window level as utility windows
window_type_hint_to_level(): applied patch from Paul Davis which moves
dialogs to NSFloatingWindowLevel. This is not quite the perfect
solution, but it's a pragmatic fix that makes apps which have both
window types much more usable, and prevents dialog from disappearing
under an application's main window.
(cherry picked from commit 59d49e1566)
2013-06-06 15:49:00 +02:00
E. K. Kato
155caad426 Bug 694273 - Patch to support NSTextInputClient in text widgets
Provides an input module for native OSX input methods.
Based on a patch by Hiroyuki Yamamoto
(http://www.sraoss.jp/sylpheed/sylpheed/macosx/gtk+-2.24.0-macosx-textinputclient_ja-test1.patch).
Adjustments for Gtk3 by Matthew Francis <gnomebugs@newsheffield.co.uk>
2013-05-20 10:48:32 -07:00
Benjamin Otte
205c16df32 quartz: Remove unused variable 2013-05-11 14:47:48 +02:00
John Ralls
e148be0d32 Fix typo in 6115961175 2013-05-10 17:25:58 -07:00
John Ralls
b75aa67bbe Remove framework initialization code
This is left over from an old effort to bundle gtk and its dependencies
into a Mac OS X Framework. The effort was more or less successful but
proved difficult to maintain and impractical to use because gtk programs
don't use the special Framework include syntax.
2013-05-10 17:25:58 -07:00
Alexander Larsson
6115961175 gdkwindow: Make GdkPaintable normal GdkWindowImpl vfuncs
There is no need for this to be a separate interface, its just looking
weird.
2013-05-07 16:33:01 +02:00
Alexander Larsson
19560bf0d4 gdkwindow: Remove translate vfunc
This is not used anymore
2013-05-07 16:33:00 +02:00
Matthias Clasen
8af16c5d44 New visibility handling in gdk
Change the visibility handling to be the same way we do it in
GLib now. We pass -fvisibility=hidden to gcc and decorate public
functions with __attribute__((visibility("default"))).

This commit just does this for GDK, GTK+ will follow later.
2013-05-05 15:38:48 -04:00
Matthias Clasen
ca81028901 Add GDK_AVAILABLE_IN_ALL annotations in gdk
This is in preparation to modernizing our handing
of exported symbols.
2013-05-05 15:38:46 -04:00
Benjamin Otte
f3a5ad32f3 quartz: Move initialization code to display_class_init
This follows the same reasoning as the X11 backend in commit
0122a9da8e
2013-05-02 15:43:35 +02:00
John Ralls
f0f07ad6d8 Remove get_atom_name and atom_intern
Completes aa9e974 for quartz
2013-04-22 15:48:35 -07:00
John Ralls
179004f0a7 Fix attempted inclusion of local headers with system brackets. 2013-04-22 15:48:34 -07:00
Benjamin Otte
a6a4428f23 gdk: Unvfuncify gdk_display_manager_open_display()
This looks like a pretty stupid patch, but it's only a step towards the
ultimate end goal: Get rid of all the displaymanagers.
2013-04-19 16:23:43 -04:00
Benjamin Otte
f345051d36 displaymanager: Emit display-opened directly
Instead of letting every backend do it manually.
2013-04-19 16:18:25 -04:00
Benjamin Otte
edbace1045 quartz: Emit GdkDisplay::opened signal 2013-04-19 16:18:25 -04:00
Benjamin Otte
065a8da87a gdk: Refactor default key vfuncs
Instead of copying them all over the place, keep a default
implementation around.
2013-04-16 15:30:14 +02:00
Benjamin Otte
a489f69e00 gdk: Remove unused function 2013-04-15 15:43:27 +02:00
Benjamin Otte
7ef508ff4a displaymanager: Handle list of displays in base class
This moves the add/remove_display() functions from the subclasses to
GdkDisplay and GdkDisplayManager. It also gets rid of the list_displays
vfunc.
2013-04-15 15:43:26 +02:00
Benjamin Otte
839f402191 displaymanager: Handle the default display
... instead of having every backend do it on their own.
2013-04-15 15:43:26 +02:00
Benjamin Otte
a6b29d73d7 gdkdisplay: Remove get_screen() and get_n_screens() vfuncs 2013-04-02 11:45:44 +02:00
Kristian Rietveld
6f607fc8b4 quartz: move atom/pasteboard type conversions functions to GDK
(cherry picked from commit a269c2f8d2)
2013-03-28 13:10:38 +01:00
Alan McGovern
e28b10d56f quartz: Null check title before setting it
This avoids a crash in objective-c.

https://bugzilla.gnome.org/show_bug.cgi?id=695278
2013-03-06 12:37:44 +01:00
John Ralls
afe8ce2ef7 Fix broken quartz build from df3e19b
It's _gdk_display, not display
2013-02-28 12:34:33 -08:00
Owen W. Taylor
df3e19b449 Broadway/Quartz/Win32: make event source prepare()/check() note paused status
When events are paused, we should not return TRUE from prepare() or check().
GTK+ handles this for events that are already in the GTK+ queue, but
we also need suppress checks for events that are in the system queue - if we
return TRUE indicating that there are events in the system queue, then we'll
call dispatch(), and do nothing. The event source will spin, and will never
run the other phases of the paint clock.

(Broadway doesn't have a window system queue separate from the GDK event queue,
but we write the function the same way for consistency.)

https://bugzilla.gnome.org/show_bug.cgi?id=694274
2013-02-21 09:59:58 -05:00
Owen W. Taylor
645b5f398d Reimplement _NET_WM_SYNC_REQUEST inside X11 backend
Deprecate gdk_window_enable_synchronized_configure() and
gdk_window_configure_done() and make them no-ops. Implement the
handling of _NET_WM_SYNC_REQUEST in terms of the frame cycle -
we know that all processing will be finished in the next frame
cycle after the ConfigureNotify is received.
2013-02-14 17:19:51 -05:00
Kristian Rietveld
1d410ec960 quartz: retain content view when switching over toplevel.
(cherry picked from commit 184407309f)
2013-01-17 14:45:33 +01:00
Kristian Rietveld
ce7d29aa89 quartz: Make sure the old toplevel is closed on recreation
(cherry picked from commit 30deba453a)
2013-01-17 14:45:07 +01:00
Kristian Rietveld
b4b42ba54d quartz: make sure all old properties are set on the new toplevel
Apply patch by Paul Davies; part of bug 669808.
(cherry picked from commit a8008b796f)
2013-01-17 14:43:15 +01:00
Kristian Rietveld
5162751f6c quartz: ensure window being (un)fullscreened is visible
Patch by Paul Davis; part of bug 669808.
(cherry picked from commit 62f1d871b7)
2013-01-17 14:40:30 +01:00
Matthias Clasen
5adecf183b Move single-include guards inside include guards
gcc has optimizations for include guards that only work
if they are outermost in the the header.
https://bugzilla.gnome.org/show_bug.cgi?id=689810
2012-12-28 09:57:56 -05:00
Michael Natterer
709f12b9ac quartz: add mountain lion as version 8 to enum GdkOSXVersion
Also use GDK_OSX_UNSUPPORTED instead of 0 in gdk_quartz_osx_version().
(cherry picked from commit 9644e910a8)
2012-11-29 15:00:57 +01:00
Michael Natterer
e2144fbb7e quartz: call Gestalt() only once per session in gdk_quartz_osx_version()
Thanks to Paul Davis for pointing this out.
(cherry picked from commit d6533ffc44)
2012-11-29 15:00:38 +01:00
Camillo Lugaresi
4f6e1fdf16 Bug 688710 - splashscreen shouldn't be always on top on OS X
Activate the "hides on deactivate" behavior for splashscreens,
torn-off menus, utility windows, tooltips and notifications: when
another application is brought to the front, these windows are hidden
so as not to obscure it. This is the expected behavior for
application-specific floating windows on OS X.
(cherry picked from commit 0596f5591f)
2012-11-20 22:03:40 +01:00
Michael Natterer
d0af25f12c quartz: fix the mapping of GDK_KP_Enter in known_numeric_keys[]
so it will actually be used, instead of delivering GDK_Return
when it should be GDK_KP_Enter.
(cherry picked from commit 27f3fcf12c)
2012-11-20 19:14:43 +01:00
Michael Natterer
455a0ecc1c quartz: always send GDK_NOTIFY_NONLINEAR crossing events
so GtkMenu works properly. This is not right, but not more
wrong than always sending GDK_NOTIFY_ANCESTOR either.
(cherry picked from commit 35a9322e45)
2012-11-20 10:35:40 +01:00
Michael Natterer
2d5ad5f54e Bug 672193 - windows (including menus) shown multiple times don't...
Based on a patch from Paul Davis, inject synthetic enter events directly
into the Quartz event stream, instead of trying to synthesize them in GDK.

This seems to magically fix most combo box popup weirdness, I guess
some code is relying on a specfic order of events, or any other state
imposed by the "proper" code path of events coming in the usual way.

The patch also removes _gdk_quartz_events_send_enter_notify_event()
which is now obsolete.

(sortof cherry-pixked from 979e5061a0
but needed manual editing because GdkQuartzWindow.c was renamed
and apparently earlier patches not picked correctly/completely)
2012-11-20 10:28:58 +01:00