Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(674)

Side by Side Diff: Source/web/PopupContainer.h

Issue 135753002: Update web classes to use OVERRIDE / FINAL when needed (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/web/PinchViewports.h ('k') | Source/web/PopupListBox.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2011, Google Inc. All rights reserved. 2 * Copyright (c) 2011, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 24 matching lines...) Expand all
35 #include "platform/PopupMenuStyle.h" 35 #include "platform/PopupMenuStyle.h"
36 #include "platform/geometry/FloatQuad.h" 36 #include "platform/geometry/FloatQuad.h"
37 #include "platform/scroll/FramelessScrollView.h" 37 #include "platform/scroll/FramelessScrollView.h"
38 38
39 namespace WebCore { 39 namespace WebCore {
40 40
41 class ChromeClient; 41 class ChromeClient;
42 class FrameView; 42 class FrameView;
43 class PopupMenuClient; 43 class PopupMenuClient;
44 44
45 class PopupContainer : public FramelessScrollView { 45 class PopupContainer FINAL : public FramelessScrollView {
46 public: 46 public:
47 enum PopupType { 47 enum PopupType {
48 Select, // HTML select popup. 48 Select, // HTML select popup.
49 Suggestion, // Autocomplete/autofill popup. 49 Suggestion, // Autocomplete/autofill popup.
50 }; 50 };
51 51
52 static PassRefPtr<PopupContainer> create(PopupMenuClient*, PopupType, bool d eviceSupportsTouch); 52 static PassRefPtr<PopupContainer> create(PopupMenuClient*, PopupType, bool d eviceSupportsTouch);
53 53
54 // Whether a key event should be sent to this popup. 54 // Whether a key event should be sent to this popup.
55 bool isInterestedInEventForKey(int keyCode); 55 bool isInterestedInEventForKey(int keyCode);
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 // While hovering popup menu window, we want to show tool tip message. 111 // While hovering popup menu window, we want to show tool tip message.
112 String getSelectedItemToolTip(); 112 String getSelectedItemToolTip();
113 113
114 // This is public for testing. 114 // This is public for testing.
115 static IntRect layoutAndCalculateWidgetRectInternal(IntRect widgetRectInScre en, int targetControlHeight, const FloatRect& windowRect, const FloatRect& scree n, bool isRTL, const int rtlOffset, const int verticalOffset, const IntSize& tra nsformOffset, PopupContent*, bool& needToResizeView); 115 static IntRect layoutAndCalculateWidgetRectInternal(IntRect widgetRectInScre en, int targetControlHeight, const FloatRect& windowRect, const FloatRect& scree n, bool isRTL, const int rtlOffset, const int verticalOffset, const IntSize& tra nsformOffset, PopupContent*, bool& needToResizeView);
116 116
117 private: 117 private:
118 friend class WTF::RefCounted<PopupContainer>; 118 friend class WTF::RefCounted<PopupContainer>;
119 119
120 PopupContainer(PopupMenuClient*, PopupType, bool deviceSupportsTouch); 120 PopupContainer(PopupMenuClient*, PopupType, bool deviceSupportsTouch);
121 ~PopupContainer(); 121 virtual ~PopupContainer();
122 122
123 // Paint the border. 123 // Paint the border.
124 void paintBorder(GraphicsContext*, const IntRect&); 124 void paintBorder(GraphicsContext*, const IntRect&);
125 125
126 // Layout and calculate popup widget size and location and returns it as Int Rect. 126 // Layout and calculate popup widget size and location and returns it as Int Rect.
127 IntRect layoutAndCalculateWidgetRect(int targetControlHeight, const IntSize& transformOffset, const IntPoint& popupInitialCoordinate); 127 IntRect layoutAndCalculateWidgetRect(int targetControlHeight, const IntSize& transformOffset, const IntPoint& popupInitialCoordinate);
128 128
129 void fitToListBox(); 129 void fitToListBox();
130 130
131 // Returns the ChromeClient of the page this popup is associated with. 131 // Returns the ChromeClient of the page this popup is associated with.
(...skipping 19 matching lines...) Expand all
151 FloatQuad m_controlPosition; 151 FloatQuad m_controlPosition;
152 IntSize m_controlSize; 152 IntSize m_controlSize;
153 153
154 // Whether the popup is currently open. 154 // Whether the popup is currently open.
155 bool m_popupOpen; 155 bool m_popupOpen;
156 }; 156 };
157 157
158 } // namespace WebCore 158 } // namespace WebCore
159 159
160 #endif 160 #endif
OLDNEW
« no previous file with comments | « Source/web/PinchViewports.h ('k') | Source/web/PopupListBox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698