summaryrefslogtreecommitdiffstats
path: root/base/message_pump_glib.h
Commit message (Collapse)AuthorAgeFilesLines
* Move some files from base to base/memory.levin@chromium.org2011-03-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | raw_scoped_refptr_mismatch_checker.h ref_counted.cc ref_counted.h ref_counted_memory.cc ref_counted_memory.h ref_counted_unittest.cc scoped_callback_factory.h scoped_comptr_win.h scoped_handle.h scoped_native_library.cc scoped_native_library.h scoped_native_library_unittest.cc scoped_nsobject.h scoped_open_process.h scoped_ptr.h scoped_ptr_unittest.cc scoped_temp_dir.cc scoped_temp_dir.h scoped_temp_dir_unittest.cc scoped_vector.h singleton.h singleton_objc.h singleton_unittest.cc linked_ptr.h linked_ptr_unittest.cc weak_ptr.cc weak_ptr.h weak_ptr_unittest.cc BUG=None TEST=Compile Review URL: http://codereview.chromium.org/6714032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@79524 0039d316-1c4b-4281-b951-d872f2087c98
* Start sorting methods in class declarations.erg@google.com2011-01-071-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | A lot of our headers are a mess and aren't organized. Impose the following order on files in the base/ directory: class Blah { each public/protected/private section: typedefs; enums; static constants; ctors; dtors; methods; overridden virtual methods; data members; }; BUG=68682 TEST=compiles Review URL: http://codereview.chromium.org/6081007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70749 0039d316-1c4b-4281-b951-d872f2087c98
* Start deinlining non-empty virtual methods. (This will be automatically checkederg@google.com2010-12-091-1/+1
| | | | | | | | | | | for in the future.) BUG=none TEST=compiles Review URL: http://codereview.chromium.org/5574006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@68746 0039d316-1c4b-4281-b951-d872f2087c98
* Switch to using TimeTicks rather than Time in message loopsjar@chromium.org2010-11-061-2/+2
| | | | | | | | | | Switch to using TimeTicks rather than Time so that we are not dependent on changes in the system clock. r=mbelshe,darin Review URL: http://codereview.chromium.org/3884001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@65322 0039d316-1c4b-4281-b951-d872f2087c98
* touchui: Directly process key and mouse events.rjkroege@google.com2010-10-261-0/+4
| | | | | | | | | | | | | | | | Capture the keyboard and mouse events directly from X, create a corresponding views::Event out of it, and send it to the associated RootView. Includes Chad's (wyck) function FindRootViewForGdkEvent (from #3704005) slightly modified (called FindRootViewForGdkWindow). BUG=None TEST=Click/Keypress events in a webpage should work correctly. Review URL: http://codereview.chromium.org/3801011 Patch from Sadrul Chowdhury <sadrul@chromium.org>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63916 0039d316-1c4b-4281-b951-d872f2087c98
* Add a message pump for touchui=1rjkroege@google.com2010-10-221-0/+9
| | | | | | | | | | | | | | | | | | | | | | | The message pump reads events directly from X. For most events, it passes them on to GDK for normal processing. It consumes some events (e.g. keypress events) to demonstrate how it's intended to work. This, of course, makes chrome mostly unusable since you can only use the mouse to do things. But this is a small first step towards capturing events through MPX (e.g. touch etc.) and processing them as chrome pleases. glib message pump: Slightly change architecture This changeset breaks down the glib message pump a little so that it can be easily subclassed. The next set of commits will introduce a subclass that still uses GTK and GDK widgets, but reads events directly from X instead of through GTK/GDK. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=63397 Review URL: http://codereview.chromium.org/3748002 Patch from Sadrul Chowdhury <sadrul@chromium.org>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63519 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 63397 - Add a message pump for touchui=1rjkroege@google.com2010-10-211-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The message pump reads events directly from X. For most events, it passes them on to GDK for normal processing. It consumes some events (e.g. keypress events) to demonstrate how it's intended to work. This, of course, makes chrome mostly unusable since you can only use the mouse to do things. But this is a small first step towards capturing events through MPX (e.g. touch etc.) and processing them as chrome pleases. glib message pump: Slightly change architecture This changeset breaks down the glib message pump a little so that it can be easily subclassed. The next set of commits will introduce a subclass that still uses GTK and GDK widgets, but reads events directly from X instead of through GTK/GDK. Review URL: http://codereview.chromium.org/3748002 Patch from Sadrul Chowdhury <sadrul@chromium.org>. TBR=rjkroege@google.com Probably a dynamic link problem with -lX11. Review URL: http://codereview.chromium.org/4007004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63403 0039d316-1c4b-4281-b951-d872f2087c98
* Add a message pump for touchui=1rjkroege@google.com2010-10-211-0/+9
| | | | | | | | | | | | | | | | | | | | | The message pump reads events directly from X. For most events, it passes them on to GDK for normal processing. It consumes some events (e.g. keypress events) to demonstrate how it's intended to work. This, of course, makes chrome mostly unusable since you can only use the mouse to do things. But this is a small first step towards capturing events through MPX (e.g. touch etc.) and processing them as chrome pleases. glib message pump: Slightly change architecture This changeset breaks down the glib message pump a little so that it can be easily subclassed. The next set of commits will introduce a subclass that still uses GTK and GDK widgets, but reads events directly from X instead of through GTK/GDK. Review URL: http://codereview.chromium.org/3748002 Patch from Sadrul Chowdhury <sadrul@chromium.org>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63397 0039d316-1c4b-4281-b951-d872f2087c98
* FBTF: Move some inner classes out of their header files.thestig@chromium.org2010-08-051-15/+1
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/3005047 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55145 0039d316-1c4b-4281-b951-d872f2087c98
* `#pragma once` for app, base, chrome, gfx, ipc, net, skia, viewsthakis@chromium.org2010-07-261-0/+1
| | | | | | | | | BUG=50273 TEST=everything still builds, build is 10% faster on windows, same speed on mac/linux TBR: erg git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53716 0039d316-1c4b-4281-b951-d872f2087c98
* Avoid including gtk & glib headers in message_pump_glib.h, saves 1 sec on ↵mattm@chromium.org2009-12-041-5/+9
| | | | | | | | | | | do-nothing make. TEST=manual browser test, trybots BUG=none Review URL: http://codereview.chromium.org/464031 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33851 0039d316-1c4b-4281-b951-d872f2087c98
* This CL adds accelerators to the Linux toolkit views.jcampan@chromium.org2009-07-311-4/+24
| | | | | | | | | | | The MessageLoop had to be modified to support Dispatchers on Linux. BUG=None TEST=On Windows and Linux, make sure the accelerators still work as expected. On Linux toolkit views, build and run the unit-tests. Review URL: http://codereview.chromium.org/159046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22210 0039d316-1c4b-4281-b951-d872f2087c98
* linux: fix main loop issues with windowless pluginsevan@chromium.org2009-06-011-5/+8
| | | | | | | | | | | | | | | | | | In certain conditions (e.g. NPN_InvalidateRect taking long), the flash plugin runs its own event loop before returning. It looks roughly like this: while (gtk_events_pending()) { gtk_main_iteration(); } The problem is that our worker source used to force gtk_events_pending() to be always true, because the Check handler always returned TRUE (and that also made HandleDispatch to always run). That caused flash animations to stop and other bad behavior (100% CPU). This CL changes the Check function to return TRUE only if HandleDispatch should be run (i.e., more_work_is_plausible set to true), while also checking whether the loop was woken up, or the delayed work timer expired. HandlePrepare was forcing more_work_is_plausible to be always true apparently to avoid starvation. I removed this, I'm not sure why it is needed. If we get starvation issue, we should raise the priority of WorkSource (for reference, most events run at prio 0, except redraws that run at prio 120. WorkSource runs at prio 200). Another possibility is to force more_work_is_plausible but only every n calls to HandlePrepare. BUG=8202,11843,12278 Review URL: http://codereview.chromium.org/115812 Patch from Antoine Labour <piman@google.com>. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17357 0039d316-1c4b-4281-b951-d872f2087c98
* Adds DidProcessEvent to MessagePumpGLib.sky@chromium.org2009-05-191-0/+7
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/113600 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16429 0039d316-1c4b-4281-b951-d872f2087c98
* Adds an observer callback to Linux's MessagePumpForUI.sky@chromium.org2009-05-151-0/+29
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/112029 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16204 0039d316-1c4b-4281-b951-d872f2087c98
* Removed unneeded includes of base/scoped_ptr.h. Reduce usage from ~800 files ↵thestig@chromium.org2009-03-131-1/+0
| | | | | | | | to ~400. Review URL: http://codereview.chromium.org/46039 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11651 0039d316-1c4b-4281-b951-d872f2087c98
* Fix the glib pump getting wedged.deanm@chromium.org2008-11-181-0/+8
| | | | | | | | I had previously used g_main_context_wakeup which uses glib's internal wakeup pipe. However, this won't ensure that our Dispatch method is called, so I think the poll() was returning, but our events never realized this so we kept on blocking infinitely. We need to make sure our Dispatch() is run when there is a wakeup, which means we have to use our own wakeup pipe so we can handle the event. Review URL: http://codereview.chromium.org/11432 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5590 0039d316-1c4b-4281-b951-d872f2087c98
* Restructure the the pump for nested loops.deanm@chromium.org2008-11-131-0/+12
| | | | | | | | Change our work dispatching to be based around an event source. This will allow us to still participate when a message loop is pumped by outside code (nested message loops). Review URL: http://codereview.chromium.org/10854 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5331 0039d316-1c4b-4281-b951-d872f2087c98
* Drop the wakeup pipe completely and use the builtin glib wakeup.deanm@chromium.org2008-11-121-10/+0
| | | | | | Review URL: http://codereview.chromium.org/10848 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5296 0039d316-1c4b-4281-b951-d872f2087c98
* Rewrite the glib UI pump. Although the previous pump was correct in terms ↵deanm@chromium.org2008-11-121-38/+5
| | | | | | | | of test coverage, it was mis-handling the concept of idle work. This meant we were effectively polling the pump, causing full CPU usage. The new pump is greatly simplified, and follows the pattern used on Windows. All tests still pass. Review URL: http://codereview.chromium.org/10833 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5278 0039d316-1c4b-4281-b951-d872f2087c98
* Review URL: http://codereview.chromium.org/8220dsh@google.com2008-11-041-0/+3
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4698 0039d316-1c4b-4281-b951-d872f2087c98
* Implement MessageLoopForUI using GLib. This gets some exercise fromdsh@google.com2008-10-031-0/+100
base_unittest. BUG=1319 Review URL: http://codereview.chromium.org/4261 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2834 0039d316-1c4b-4281-b951-d872f2087c98