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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLSelectElement.h

Issue 2143863003: Simplify protocol between SELECT elements and popups. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@select-remove-fixed-args
Patch Set: Created 4 years, 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). 2 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
4 * (C) 1999 Antti Koivisto (koivisto@kde.org) 4 * (C) 1999 Antti Koivisto (koivisto@kde.org)
5 * (C) 2000 Dirk Mueller (mueller@kde.org) 5 * (C) 2000 Dirk Mueller (mueller@kde.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved.
7 * Copyright (C) 2010 Google Inc. All rights reserved. 7 * Copyright (C) 2010 Google Inc. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 String itemText(const Element&) const; 142 String itemText(const Element&) const;
143 bool itemIsDisplayNone(Element&) const; 143 bool itemIsDisplayNone(Element&) const;
144 // itemComputedStyle() returns nullptr only if the owner Document is not 144 // itemComputedStyle() returns nullptr only if the owner Document is not
145 // active. So, It returns a valid object when we open a popup. 145 // active. So, It returns a valid object when we open a popup.
146 const ComputedStyle* itemComputedStyle(Element&) const; 146 const ComputedStyle* itemComputedStyle(Element&) const;
147 IntRect elementRectRelativeToViewport() const; 147 IntRect elementRectRelativeToViewport() const;
148 // Text starting offset in LTR. 148 // Text starting offset in LTR.
149 LayoutUnit clientPaddingLeft() const; 149 LayoutUnit clientPaddingLeft() const;
150 // Text starting offset in RTL. 150 // Text starting offset in RTL.
151 LayoutUnit clientPaddingRight() const; 151 LayoutUnit clientPaddingRight() const;
152 void valueChanged(unsigned listIndex); 152 void selectOptionByPopup(int listIndex);
153 // TODO(tkent): Rename this. This is used only for multiple-selection 153 void selectMultipleOptionsByPopup(const Vector<int>& listIndices);
154 // menulist.
155 void listBoxSelectItem(int listIndex, bool allowMultiplySelections, bool fir eOnChangeNow);
156 // A popup is canceled when the popup was hidden without selecting an item. 154 // A popup is canceled when the popup was hidden without selecting an item.
157 void popupDidCancel(); 155 void popupDidCancel();
158 // Provisional selection is a selection made using arrow keys or type ahead. 156 // Provisional selection is a selection made using arrow keys or type ahead.
159 void provisionalSelectionChanged(unsigned); 157 void provisionalSelectionChanged(unsigned);
160 void popupDidHide(); 158 void popupDidHide();
161 bool popupIsVisible() const { return m_popupIsVisible; } 159 bool popupIsVisible() const { return m_popupIsVisible; }
162 HTMLOptionElement* optionToBeShown() const; 160 HTMLOptionElement* optionToBeShown() const;
163 void showPopup(); 161 void showPopup();
164 void hidePopup(); 162 void hidePopup();
165 PopupMenu* popup() const { return m_popup.get(); } 163 PopupMenu* popup() const { return m_popup.get(); }
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 292
295 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, FirstSelectableOption); 293 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, FirstSelectableOption);
296 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, LastSelectableOption); 294 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, LastSelectableOption);
297 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, NextSelectableOption); 295 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, NextSelectableOption);
298 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, PreviousSelectableOption); 296 FRIEND_TEST_ALL_PREFIXES(HTMLSelectElementTest, PreviousSelectableOption);
299 }; 297 };
300 298
301 } // namespace blink 299 } // namespace blink
302 300
303 #endif // HTMLSelectElement_h 301 #endif // HTMLSelectElement_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698