summaryrefslogtreecommitdiffstats
path: root/views/focus
Commit message (Collapse)AuthorAgeFilesLines
* Disabling a focus related unit test on Linux (toolkit_views).jcampan@chromium.org2009-09-221-6/+4
| | | | | | | | | | | | This test fails when the screen is locked. BUG=None TEST=None TBR=nsylvain Review URL: http://codereview.chromium.org/214052 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26813 0039d316-1c4b-4281-b951-d872f2087c98
* Land http://codereview.chromium.org/206025 for Charlie:sky@chromium.org2009-09-161-0/+1
| | | | | | | | | | | | Fix settings page transparent background issue Also comment out focus manager check due to bug: http://crbug.com/21378 TEST=none BUG=none Review URL: http://codereview.chromium.org/194128 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26370 0039d316-1c4b-4281-b951-d872f2087c98
* Lands http://codereview.chromium.org/193032 for Charlie:sky@chromium.org2009-09-151-2/+4
| | | | | | | | | | | | | | | First pass at adding ChromeOS settings - a mock wifi selector combobox - touchpad settings that makes calls to synclient - on startup, touchpad settings are initialized to what's stored in preferences TEST=none BUG=none Review URL: http://codereview.chromium.org/203073 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@26259 0039d316-1c4b-4281-b951-d872f2087c98
* Improving the FocusManager::GetFocusManager method on Gtk.jcampan@chromium.org2009-09-081-6/+7
| | | | | | | | | | BUG=None TEST=Run the FocusManager unit tests Review URL: http://codereview.chromium.org/200020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25660 0039d316-1c4b-4281-b951-d872f2087c98
* The FocusManager stores/restores focus when the top window becomes ↵jcampan@chromium.org2009-09-013-61/+98
| | | | | | | | | | | | inactive/active. BUG=None TEST=Run the focus manager unit-tests. Review URL: http://codereview.chromium.org/164448 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25108 0039d316-1c4b-4281-b951-d872f2087c98
* Try to fix the ChromeOS build. This tries to add a views dependency for ↵brettw@chromium.org2009-08-221-3/+4
| | | | | | | | browser_tests, and fixes some simple errors in the focus unit test. Review URL: http://codereview.chromium.org/173243 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24061 0039d316-1c4b-4281-b951-d872f2087c98
* Factor out views::Combobox::Model so that it can be used cross-platform.mattm@chromium.org2009-08-181-6/+7
| | | | | | | | | | This removes the Combobox* source arg from the Model methods, which wasn't really used by anything. BUG=none TEST=none Review URL: http://codereview.chromium.org/165514 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23603 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes bug in previous change. In AcceleratorHandler if there is nosky@chromium.org2009-08-111-0/+1
| | | | | | | | | | | WidgetGtk we should dispatch the event, not eat it. BUG=none TEST=none Review URL: http://codereview.chromium.org/165183 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23009 0039d316-1c4b-4281-b951-d872f2087c98
* Fixes bug in AcceleratorHandler. It's possible to get events for GtkWidgetssky@chromium.org2009-08-071-0/+5
| | | | | | | | | | | | outside of those created by Chrome that we need to ignore. I saw this with drag and drop. BUG=none TEST=none Review URL: http://codereview.chromium.org/165150 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22801 0039d316-1c4b-4281-b951-d872f2087c98
* Making the focus manager unit-tests less Windows specific.jcampan@chromium.org2009-08-041-76/+56
| | | | | | | | | | This is part of the FocusManager port on toolkit_views. BUG=None TEST=All FocusManager unit-tests should pass. Review URL: http://codereview.chromium.org/160601 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22417 0039d316-1c4b-4281-b951-d872f2087c98
* This CL adds accelerators to the Linux toolkit views.jcampan@chromium.org2009-07-316-140/+278
| | | | | | | | | | | 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
* Refactoring of tabbed-pane component so it can be ported to Linux toolkit_view.jcampan@chromium.org2009-07-211-5/+7
| | | | | | | | BUG=None TEST=Make sure the Options dialog still works as expected (tab selection, focus traversal...) Review URL: http://codereview.chromium.org/155668 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21189 0039d316-1c4b-4281-b951-d872f2087c98
* Allow TabContentsDelegates to process unhandled keyboard messages coming ↵ananta@chromium.org2009-07-142-69/+0
| | | | | | | | | | | | | | | | | | | back from the renderer. This is required for ExternalTabContainer to be able to pass unhandled keyboard accelerator messages back to the external host. This worked before as the focus manager would hand off these messages to keystroke listeners like the ExternalTabContainer. However with the ExternalTabContainer no longer using the focus manager this does not work anymore. Removed the keystroke listener code from the focus manager as the ExternalTabContainer was the only consumer and it does not use it anymore. This fixes bug http://b/issue?id=1975749 Bug=1975749 Review URL: http://codereview.chromium.org/149520 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20600 0039d316-1c4b-4281-b951-d872f2087c98
* Fix compilation error in the focus manager by returning NULL from ↵brettw@chromium.org2009-06-301-0/+1
| | | | | | | | unimplemented function. Review URL: http://codereview.chromium.org/152001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19649 0039d316-1c4b-4281-b951-d872f2087c98
* This CL removes the last (major) Windows specific part out of the focus ↵jcampan@chromium.org2009-06-306-280/+96
| | | | | | | | | | | | | | | | | | | | | | | manager. It was previously landed and reverted because it broke the reliability tests. http://codereview.chromium.org/125148 The breakage was caused by constrained windows not getting a hold of the FocusManager when in unparented tabs. The fix is to ensure unparented tab still have a way to access their FocusManager for proper closure. Files changed from the previous patch that need reviewing: native_tab_contents_container_win.cc tab_contents_view_win.h tab_contents_view_win.cc BUG=None TEST=Run all tests (unit, ui, interactive). Extensively test the focus in Chrome. Review URL: http://codereview.chromium.org/146093 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19617 0039d316-1c4b-4281-b951-d872f2087c98
* Review URL: http://codereview.chromium.org/150051jcampan@chromium.org2009-06-301-0/+20
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19582 0039d316-1c4b-4281-b951-d872f2087c98
* Revert :nsylvain@chromium.org2009-06-226-95/+280
| | | | | | | | | | | | | | | | | | Changed by: jcampan@chromium.org Changed at: Fri 19 Jun 2009 21:22:47 Branch: src Revision: 18889 Comments: Relanding focus manager refactoring with build fix, see:http://codereview.chromium.org/125148BUG=NoneTEST=NoneTBR=ben Review URL: http://codereview.chromium.org/141013 Because it creates hundreds of new reliability crashes. TBR:jcampan Review URL: http://codereview.chromium.org/140064 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18904 0039d316-1c4b-4281-b951-d872f2087c98
* Relanding focus manager refactoring with build fix, ↵jcampan@chromium.org2009-06-206-280/+95
| | | | | | | | see:http://codereview.chromium.org/125148BUG=NoneTEST=NoneTBR=ben Review URL: http://codereview.chromium.org/141013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18889 0039d316-1c4b-4281-b951-d872f2087c98
* Reverting 18872.jcampan@chromium.org2009-06-196-95/+280
| | | | | | | | | | | | Broke the Windows build. BUG=None TEST=None TBR=ben Review URL: http://codereview.chromium.org/140023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18873 0039d316-1c4b-4281-b951-d872f2087c98
* Removed the last Windows specific part out of the focus manager. HWNDs are ↵jcampan@chromium.org2009-06-196-280/+95
| | | | | | | | not subclassed anymore.The FocusManager is now created and owned by top-level WidgetWins.BUG=NoneTEST=Run the unit tests, UI tests, interactive UI tests. Fully test the focus behavior in the browser: activate/deactivate the browser windows, make sure focus is remembered. Switch tabs, make sure focus is remembered for each tab. make sure accelerators work as expected. Test focus traversal in a web page, in the option dialog. Review URL: http://codereview.chromium.org/125148 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18872 0039d316-1c4b-4281-b951-d872f2087c98
* Fix focus traversal cycle.yutak@chromium.org2009-06-153-40/+11
| | | | | | | | | | This change makes traversal order of focus cycle consistent between forward and backward traversal. This is a partial fix for issue 6785. BUG=http://crbug.com/6785 TEST=Move the focus to the find bar, and push [Shift]+[Tab]. The focus should not cycle inside the find bar, but go out to the omnibox (or somewhere outside the find bar). Review URL: http://codereview.chromium.org/125130 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18402 0039d316-1c4b-4281-b951-d872f2087c98
* Fix reversed focus traversal order issue.yutak@chromium.org2009-06-123-45/+26
| | | | | | | | | | | | | | | | This change fixes several problems in handling focus traversal and resolves TabbedPane's traversal order issue. Reversed focus traversal is very tricky, and the original traversal code overlooked several things. (1) A focusable view may have a FocusTraverasble. (2) When we are going down, we have to check if the current view has a FocusTraversable. (3) When we are going up from a FocusTraversable, the parent view may gain the next focus. This change fixes these issues. BUG=6871 TEST=See issue 6871. Review URL: http://codereview.chromium.org/125062 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18335 0039d316-1c4b-4281-b951-d872f2087c98
* Changing the focus manager to not subclass HWNDs (but for the ↵jcampan@chromium.org2009-06-123-29/+39
| | | | | | | | top-windows).Components that have HWND now need to specifically let the FocusManager know when they get the native focus.This is the reason for the new GotFocus() notification on the RenderWidgetHostViewWin class.BUG=NoneTEST=Run the interactive tests, the unit-tests. Test that the focus is remembered correctly when switching windows, switching tabs. Test that focus traversal in the browser and in the option dialog works as expected. Review URL: http://codereview.chromium.org/122002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18301 0039d316-1c4b-4281-b951-d872f2087c98
* Fix a memory leak in a focus manager unit-test.jcampan@chromium.org2009-06-091-2/+2
| | | | | | | | BUG=None TEST=None Review URL: http://codereview.chromium.org/118461 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17986 0039d316-1c4b-4281-b951-d872f2087c98
* This CL adds some more FocusManager unit-tests.jcampan@chromium.org2009-06-091-223/+494
| | | | | | | | BUG=None TEST=Run the unit-tests. Review URL: http://codereview.chromium.org/118413 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17951 0039d316-1c4b-4281-b951-d872f2087c98
* Moving the Windows specific activation code in the FocusManager to the ↵jcampan@chromium.org2009-06-082-29/+2
| | | | | | | | | | widget_win. BUG=None TEST=Test that the focus in the browser works well: that windows remember which view had focus when deactivated/reactivated. Make sure focus traversal works as expected. Review URL: http://codereview.chromium.org/118406 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17911 0039d316-1c4b-4281-b951-d872f2087c98
* Fix keyboard accelerator registration issue in views::View.yutak@chromium.org2009-06-061-4/+2
| | | | | | | | | | View should not register the same accelerator target multiple times. BUG=13275 TEST=None Review URL: http://codereview.chromium.org/118242 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17810 0039d316-1c4b-4281-b951-d872f2087c98
* Fix: Alt+Tab not sending FocusWillChange events.finnur@chromium.org2009-06-041-5/+4
| | | | | | | | | | | | | This causes a DCHECK in FindBarWin if the Find box is open when the user switches to another app with Alt+Tab. The Focus manager now calls ClearFocus everywhere it used to set focused_view_ = NULL, to make sure the event reaches all listeners for FocusWillChange. BUG=13350 TEST=Open Chrome, press Ctrl+F then Alt+Tab. Swith focus back to Chrome and press Esc multiple times and you should not see the Find box flash briefly. Review URL: http://codereview.chromium.org/118267 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17678 0039d316-1c4b-4281-b951-d872f2087c98
* Some previous refactoring I did of the accelerator code had introduced ↵jcampan@chromium.org2009-06-031-4/+1
| | | | | | | | regressions (pressing ESC would close the dialog instead of closing an opened combo-box, pressing enter on a dialog with a focused link would not open the link).Looking at fixing these I realized the method View::OvverideAccelerator was not needed anymore as View::SkipDefaultKeyEventProcessing supersedes it.So I removed View::OvverideAccelerator. As a result I also ended up moving some Windows specific code from LocationbarView to AutocompleteEditViewWin.BUG=6900TEST=Open the option dialog, click on a combo-box to open the drop-down list. Press ESC, the drop-down list should be closed. Move the focus to a link (by pressing Tab). Press Enter, the link should be opened and the option dialog should not be closed. Make sure that accelerators (ESC, tab, key up/down...) still work ok in the omnibox) Review URL: http://codereview.chromium.org/119016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17544 0039d316-1c4b-4281-b951-d872f2087c98
* FocusManager should accept multiple AcceleratorTargets for each accelerator.yutak@chromium.org2009-06-033-46/+221
| | | | | | | | | | Originally, FocusManager automatically unregisters an old target if multiple AcceleratorTargets are registered to the same accelerator. This behavior is somewhat troublesome, and actually ShelfItemDialog hits a run-time assertion due to the conflict of registrations (issue 12401). This change modifies the behavior of FocusManager to allow multiple targets to be registered for each accelerator. BUG=12401 TEST=See if issue 12401 is resolved. Review URL: http://codereview.chromium.org/114065 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17533 0039d316-1c4b-4281-b951-d872f2087c98
* Recent refactoring of the combobox had broken focus.jcampan@chromium.org2009-06-031-21/+40
| | | | | | | | | BUG=13256 TEST=Open the option dialog. Move the focus around by pressing tab, make sure the combobox gets focused correctly. When the focus is on the combobox, activate another (non Chromium) window, then come back to the option dialog, the focus should still be on the combobox. Review URL: http://codereview.chromium.org/118175 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17526 0039d316-1c4b-4281-b951-d872f2087c98
* Refactors HWNDView, NativeViewHostGtk and NativeViewHost so that they match ↵ben@chromium.org2009-05-291-1/+1
| | | | | | | | | | the NativeControl pattern established for NativeButtons. NativeViewHost is a platform-neutral class that clients instantiate. Behind the scenes the platform instantiates the appropriate NativeViewHostWrapper implementation, either NativeViewHostGtk (as before) or NativeViewHostWin (replaces HWNDView). BUG=none TEST=none Review URL: http://codereview.chromium.org/114059 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17169 0039d316-1c4b-4281-b951-d872f2087c98
* Move text_field.cc and rename the class to Textfield in preparation for porting.ben@chromium.org2009-05-271-23/+23
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/115825 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17014 0039d316-1c4b-4281-b951-d872f2087c98
* Stubs out FocusManager and Menu so they compile on Linux.sky@chromium.org2009-05-262-9/+49
| | | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/115794 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16928 0039d316-1c4b-4281-b951-d872f2087c98
* Makes FindBarWin buildable on linux. FindBarWin should be renamed tosky@chromium.org2009-05-231-3/+5
| | | | | | | | | | | FindBarViews, but I'm leaving it as is for now. BUG=none TEST=none Review URL: http://codereview.chromium.org/113793 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16830 0039d316-1c4b-4281-b951-d872f2087c98
* Clean-up of the accelerator code.jcampan@chromium.org2009-05-142-27/+30
| | | | | | | | | | | | | | | The View::CanProcessTabKeyEvents and View::ShouldLookUpAccelerator have both been replaced with a new method, SkipDefaultKeyEventProcessing. This new method provides for a view that has focus a way to prevent a key event from being processed for tab traversal or accelerators. Also, fixed a regression where the Ctrl-Tab accelerator was not working anymore when the omnibox was focused. BUG=11538 TEST=Thoroughly test accelerators, making sure they work when the page, the omnibox and the find-bar text-field have focus. Also test that tab traversal still work as expected in the browser and in the option dialog. Review URL: http://codereview.chromium.org/113307 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16037 0039d316-1c4b-4281-b951-d872f2087c98
* This CL updates chrome to the latest version of skia, retrieved via DEPS, andsenorblanco@chromium.org2009-05-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | placed in third_party. All relevant skia changes (for all 3 platforms) have been upstreamed. Most of this CL is mind-numbingly repetitive. Things of interest are: skia.gyp (now points at third_party versions), DEPS, and SkUserConfig.h. stdint.h: Skia now requires C99 integer types, which MSVC doesn't support natively. I have put typedefs in config/win/stdint.h. Note that the new version of skia appears to render rects whose coordinates are "backwards" (ie., x2 < x1 or y2 < y1), which were formerly culled. There were a couple obvious instances of this in the code which I fixed, but there may be more. There were ~35 layout test failures due to minor pixel differences which I rebaselined on Windows and Linux, and 8 genuine failures related to masks and stroked text, which I have put in text_expectations.txt and assigned to myself. (There was another change which broke ~1700 tests on each platform, but I put that change behind an #ifdef for now). R=brettw Review URL: http://codereview.chromium.org/65012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15949 0039d316-1c4b-4281-b951-d872f2087c98
* Removing floating views, they are not used anymore.jcampan@chromium.org2009-05-112-97/+23
| | | | | | | | | BUG=None TEST=Run unit_tests, ui_tests, interactive ui_tests. Make sure focus traversal still works. Review URL: http://codereview.chromium.org/113215 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15817 0039d316-1c4b-4281-b951-d872f2087c98
* A new DEPS file for views, designed to reduce dependencies. Removes some ↵ben@chromium.org2009-05-081-1/+0
| | | | | | | | | | unnecessary includes too. http://crbug.com/11387 Review URL: http://codereview.chromium.org/115114 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15610 0039d316-1c4b-4281-b951-d872f2087c98
* Move src/chrome/views to src/views. RS=darin http://crbug.com/11387ben@chromium.org2009-05-089-0/+2272
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15604 0039d316-1c4b-4281-b951-d872f2087c98