summaryrefslogtreecommitdiffstats
path: root/ui/views
Commit message (Collapse)AuthorAgeFilesLines
* rename getBitmapDC to beginPlatformPaint and add calls to endPlatformPaintvandebo@chromium.org2011-04-051-1/+2
| | | | | | | | | | | This takes a step toward unifying the platform device interface between Windows and Linux and helps to make VectorPlatformDeviceSkia have less ifdefs. BUG=NONE TEST=NONE Review URL: http://codereview.chromium.org/6677142 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80474 0039d316-1c4b-4281-b951-d872f2087c98
* Consolidate Widget Event code, other cleanup.msw@chromium.org2011-03-313-24/+7
| | | | | | | | | | | | | Rename *NativeCapture to *MouseCapture. Rename and move ShouldReleaseCaptureOnMouseReleased. Move static flag function to Event. BUG=72040 TEST=Mouse interaction on win & linux_views. Review URL: http://codereview.chromium.org/6756043 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80065 0039d316-1c4b-4281-b951-d872f2087c98
* Disambiguate OnMouseCaptureLost from OnMouseReleased.msw@chromium.org2011-03-291-5/+0
| | | | | | | | | | | | | Nix RenderWidgetHostViewViews' OnMouseCaptureLost forwarding. Consolidate code, remove unnecessary overrides, etc. Fix up test, |event| args, OVERRIDEs, and (c) dates. BUG=72040 TEST=Views mouse button release, cancelling mouse down/drag. Review URL: http://codereview.chromium.org/6685069 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@79640 0039d316-1c4b-4281-b951-d872f2087c98
* Move some files from base to base/memory.levin@chromium.org2011-03-287-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Normalize the top-level ui/ module.rsesek@chromium.org2011-03-181-201/+0
| | | | | | | | | | | | | | | | This CL creates four .gypi files that are included in /ui/ui.gyp. This allows for a single unittest binary for all the submodules, rather than having individual unittest binaries for each submodule. To not break the buildbot, this creates a fake target that copies ui_unittests to gfx_unittests as temporary scaffolding. BUG=72317 TEST=gfx_unittests (really ui_unittests) passes Review URL: http://codereview.chromium.org/6688007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78711 0039d316-1c4b-4281-b951-d872f2087c98
* Update OnMouseActivate override signatures.msw@chromium.org2011-03-091-16/+16
| | | | | | | | | | | | Add OVERRIDE keyword liberally to some relevant overrides. Fix copyright dates. BUG=75366 TEST=Omnibox clicking, etc. Review URL: http://codereview.chromium.org/6648018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77431 0039d316-1c4b-4281-b951-d872f2087c98
* Carnitas: Move app_strings to ui/base/stringssail@chromium.org2011-03-081-1/+1
| | | | | | | | | | To fix circular dependencies between ui/base/ui_base.gyp and app/app.gyp I'm moving app_strings to ui/base/strings. BUG=72317 TEST=Compiled on Mac, Linux, Windows. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77337 0039d316-1c4b-4281-b951-d872f2087c98
* Add new MouseEvent ctors; update WidgetWin & WindowWin usage.msw@chromium.org2011-03-081-25/+17
| | | | | | | | | BUG=72040 TEST=Manual mouse event testing. Review URL: http://codereview.chromium.org/6591120 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77221 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 77068 - Carnitas: Move app_strings to ui/base/stringssail@chromium.org2011-03-071-1/+1
| | | | | | | | | | | | | | To fix circular dependencies between ui/base/ui_base.gyp and app/app.gyp I'm moving app_strings to ui/base/strings. BUG=72317 TEST=Compiled on Mac, Linux, Windows. Review URL: http://codereview.chromium.org/6541035 TBR=sail@chromium.org Review URL: http://codereview.chromium.org/6623055 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77142 0039d316-1c4b-4281-b951-d872f2087c98
* Carnitas: Move app_strings to ui/base/stringssail@chromium.org2011-03-061-1/+1
| | | | | | | | | | | To fix circular dependencies between ui/base/ui_base.gyp and app/app.gyp I'm moving app_strings to ui/base/strings. BUG=72317 TEST=Compiled on Mac, Linux, Windows. Review URL: http://codereview.chromium.org/6541035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77068 0039d316-1c4b-4281-b951-d872f2087c98
* Do all OOLing in the views code. linux_views now builds clean with the clang ↵erg@google.com2011-03-042-1/+6
| | | | | | | | | | | plugin. BUG=carnitas TEST=compiles Review URL: http://codereview.chromium.org/6622002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76992 0039d316-1c4b-4281-b951-d872f2087c98
* Rename ContextMenuController::ShowContextMenu() to ShowContextMenuForView().thakis@chromium.org2011-03-041-3/+3
| | | | | | | | | | | | | | | For classes deriving from both View and ContextMenuController, this makes it clear which of method is overridden. Rename TabController::ShowContextMenu to ShowContextMenuForTab for the same reason. No intended functionality change. BUG=70465,72205 TEST=none TBR=beng git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76878 0039d316-1c4b-4281-b951-d872f2087c98
* Rename the methods in DragController.thakis@chromium.org2011-03-041-7/+7
| | | | | | | | | | | | | | | They used to have the same name as methods in View. Some views would derive from both View and DragController, which was confusing. For example for clang's -Woverride-virtual. No functionality change. BUG=70465,72205 TEST=none Review URL: http://codereview.chromium.org/6609033 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76847 0039d316-1c4b-4281-b951-d872f2087c98
* Update LocatedEvent and MouseWheelEvent.msw@chromium.org2011-02-252-4/+6
| | | | | | | | | | | | | | | Refactor RootView::OnMouseWheel and WidgetGtk::ProcessScroll. Rename RootView's and MenuHostRootView's ProcessMouseWheelEvent to OnMouseWheel. Merge event_x's GetMouseEventType into EventTypeFromNative and detect wheel events. Update NativeWidgetWin::MakeMSG and WidgetWin::MakeMSG. Add some needed support functions. BUG=72040 TEST=none Review URL: http://codereview.chromium.org/6469106 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76001 0039d316-1c4b-4281-b951-d872f2087c98
* View API/implementation cleanup:pkasting@chromium.org2011-02-2213-368/+344
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Don't include the container type ("vector") in the typedef for "a bunch of children". Users generally should not know or care what the container is, so this makes reading easier as the code is not constantly pointing out to you, "hey! I'm a vector!" Added bonus: less verbose, allows condensing a lot of loop declarations onto one line. * Consistently put getters before setters. * Remove 4-arg form of SetBounds() and make people use Rects (we should move the codebase towards Points, Sizes, and Rects wherever possible). * Use "origin" instead of "position" to be consistent with Rect's terminology. * Minor naming changes, e.g. GetViewById() -> GetViewByID(). * Remove const qualifier on member functions that are not logically const. This also got rid of all the const_cast<>()s. * Better comments. * Use const ref args for Views whenever the provided View is not being modified, to make that obvious to the caller. * Turn some accessors into pairs of (non-const, const) accessors. In these cases make the non-const version call the const version. (GetWidget() does this in the header because the const version is virtual; this way people who override the const version can see why they don't need to override the non-const version). * Make RemoveChildView() take a bool for consistency with RemoveAllChildViews() (also eliminates the need to return a View*). * Add STL-style iterators and rename a few accessors to match STL terminology ("size" instead of "count"). * Turn IsFocusable() into a cheap inline getter. * Greatly simplify private tree ops ("NotifyHierarchyChangedXXX()") by realizing that they were always being called with |parent| == |this|. * Declare iterators inside loops, not above them. * Standardize iterator naming to |i|. The existing code wasn't always consistent, and while there's nothing wrong with |it|, using that would have made almost every loop declaration into two lines instead of one. * Simpler code, sometimes by using STL algorithms. * Unindent via early-returns. * Use CHECK_NE() and similar where possible. * Fix memory corruption in RemoveAllChildViews() due to using an iterator after modifying its container. BUG=none TEST=none Review URL: http://codereview.chromium.org/6541030 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@75642 0039d316-1c4b-4281-b951-d872f2087c98
* Removing the experimental Chrome extension popup API. This API will not be ↵twiz@chromium.org2011-02-141-1/+1
| | | | | | | | | | | | | | | | | | added to the set of available extension APIs. I also removed some of the plumbing associated with the popup api: - Drop-shadow support removed from BrowserBubble. This had only been supported on Windows. - Removed the ExtensionPopup::PopupChrome type. Only popups from the popup API supported rectangle chrome. - Removed the activate-on-show parameter from ExtensionPopup. This was only used for the popup API. All popups activate on show, by default. - Removed the AddRef/Release magic from ExtensionPopup. The API required these semantics because of the complex, asynchronous lifetime management required by the popup API. See ExtensionPopup::Observer::ExtensionPopupClosed. - Removed unneeded methods from ExtensionPopup::Observer, and ExtensionFunctionDispatcher::Delegate. BUG=None TEST=None Review URL: http://codereview.chromium.org/6334101 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@74835 0039d316-1c4b-4281-b951-d872f2087c98
* Migrate Event API methods to Google Style.ben@chromium.org2011-02-102-30/+30
| | | | | | | | | | | | | | Re-landing, moving the bits Mac uses to ui/base/events.h BUG=72040 TEST=none TBR=sky Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=74377 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@74408 0039d316-1c4b-4281-b951-d872f2087c98
* Change includes of gfx/* to ui/gfx/*sail@chromium.org2011-02-0512-18/+18
| | | | | | | | | BUG=71063 TEST=compiled Review URL: http://codereview.chromium.org/6312156 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73890 0039d316-1c4b-4281-b951-d872f2087c98
* Switch to using FocusEvent for focus change notifications. ben@chromium.org2011-02-0311-374/+175
| | | | | | | | | | | | | I also removed ViewStorage usage for now. Jay described generally the kind of cases where this might be useful but I have not encountered them yet in my current testing. I will reintroduce this code if it becomes necessary. Note that I have not yet verified that this works. That comes next. BUG=none TEST=none Review URL: http://codereview.chromium.org/6368083 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73655 0039d316-1c4b-4281-b951-d872f2087c98
* Method sorting.ben@chromium.org2011-02-033-397/+420
| | | | | | | | | | | | | | - Sort focus_manager.cc to match focus_manager.h - Re-sort view.cc so each visibility (public, protected, private, private members) match and are grouped relative to purpose. BUG=none TEST=none TBR=sky Review URL: http://codereview.chromium.org/6250132 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73634 0039d316-1c4b-4281-b951-d872f2087c98
* Complete the Focus Manager hookup.ben@chromium.org2011-02-0313-69/+154
| | | | | | | | | | | | | - Temporarily patch in old Focus Sibling initialization code. - Improve the constness of FocusSearch - Simplify ContainsView method in FocusManager BUG=none TEST=none Review URL: http://codereview.chromium.org/6349080 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73632 0039d316-1c4b-4281-b951-d872f2087c98
* Verify that:ben@chromium.org2011-02-037-11/+56
| | | | | | | | | | | | - RequestFocus() works. - Removing the focused view from the view hierarchy resets the focused view in the FocusManager. BUG=none TEST=unittest Review URL: http://codereview.chromium.org/6286073 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73621 0039d316-1c4b-4281-b951-d872f2087c98
* More FocusManager hookup.ben@chromium.org2011-02-0314-37/+179
| | | | | | | | | | | | | | - One focus manager per Widget hierarchy - Create focus manager on widget initialization - Allow focus manager to be obtained from NativeView. - Adds a test to ensure focus manager is only created for the top level widget. BUG=none TEST=none Review URL: http://codereview.chromium.org/6349057 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73551 0039d316-1c4b-4281-b951-d872f2087c98
* Fix checkdeps by deleting not-built file.ben@chromium.org2011-02-021-1730/+0
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73519 0039d316-1c4b-4281-b951-d872f2087c98
* Copy more focus manager into V2. Comment out a bunch of stuff and add stub ↵ben@chromium.org2011-02-0214-0/+3461
| | | | | | | | | | | impls of methods with TODOs so that it builds. BUG=none TEST=none Review URL: http://codereview.chromium.org/6334062 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73513 0039d316-1c4b-4281-b951-d872f2087c98
* Begin to integrate Focus Manager. Add Windows accelerator handler ↵ben@chromium.org2011-02-028-2/+284
| | | | | | | | | | | implementation (commented out now due to lack of focus manager). Add some utilities to NativeWidget for obtaining NativeWidget from a NativeView. BUG=none TEST=none Review URL: http://codereview.chromium.org/6286035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73479 0039d316-1c4b-4281-b951-d872f2087c98
* Reorder methods in class View to better isolate methods that shouldn't be ↵ben@chromium.org2011-02-014-129/+167
| | | | | | | | | | | | | public. Specifically, move most event handlers and processing functions to protected now that RootView is a friend. BUG=none TEST=compiles, existing unittests Review URL: http://codereview.chromium.org/6286032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73376 0039d316-1c4b-4281-b951-d872f2087c98
* sFirst cut at an experiment with what a simplified View/Widget API would ↵ben@chromium.org2011-02-0141-0/+4138
look like. Of note: - Widget is a cross-platform class encapsulating widget-specific state - NativeWidget interface wraps different implementations of a native widget. Starting with HWND. - NativeWidget implementation should eventually be swappable at runtime. - Simpler Event construction directly from a NativeEvent (e.g. MSG struct) - Simpler View API with fewer, more clearly delineated overrides. Notes: - Window* are just empty files for now while I get View/Widget to work. BUG=none TEST=see unittests, in development Review URL: http://codereview.chromium.org/6286013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73353 0039d316-1c4b-4281-b951-d872f2087c98