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

Side by Side Diff: third_party/WebKit/Source/core/dom/Element.h

Issue 1840113005: Move viewport actions into an ApplyScroll callback. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Peter Kelly (pmk@post.com) 4 * (C) 2001 Peter Kelly (pmk@post.com)
5 * (C) 2001 Dirk Mueller (mueller@kde.org) 5 * (C) 2001 Dirk Mueller (mueller@kde.org)
6 * Copyright (C) 2003-2011, 2013, 2014 Apple Inc. All rights reserved. 6 * Copyright (C) 2003-2011, 2013, 2014 Apple Inc. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 virtual const AtomicString imageSourceURL() const; 392 virtual const AtomicString imageSourceURL() const;
393 virtual Image* imageContents() { return nullptr; } 393 virtual Image* imageContents() { return nullptr; }
394 394
395 virtual void focus(const FocusParams& = FocusParams()); 395 virtual void focus(const FocusParams& = FocusParams());
396 virtual void updateFocusAppearance(SelectionBehaviorOnFocus); 396 virtual void updateFocusAppearance(SelectionBehaviorOnFocus);
397 virtual void blur(); 397 virtual void blur();
398 398
399 void setDistributeScroll(ScrollStateCallback*, String nativeScrollBehavior); 399 void setDistributeScroll(ScrollStateCallback*, String nativeScrollBehavior);
400 void nativeDistributeScroll(ScrollState&); 400 void nativeDistributeScroll(ScrollState&);
401 void setApplyScroll(ScrollStateCallback*, String nativeScrollBehavior); 401 void setApplyScroll(ScrollStateCallback*, String nativeScrollBehavior);
402 void removeApplyScroll();
402 void nativeApplyScroll(ScrollState&); 403 void nativeApplyScroll(ScrollState&);
403 404
404 void callDistributeScroll(ScrollState&); 405 void callDistributeScroll(ScrollState&);
405 void callApplyScroll(ScrollState&); 406 void callApplyScroll(ScrollState&);
406 407
408 ScrollStateCallback* getApplyScroll();
409
407 // Whether this element can receive focus at all. Most elements are not 410 // Whether this element can receive focus at all. Most elements are not
408 // focusable but some elements, such as form controls and links, are. Unlike 411 // focusable but some elements, such as form controls and links, are. Unlike
409 // layoutObjectIsFocusable(), this method may be called when layout is not u p to 412 // layoutObjectIsFocusable(), this method may be called when layout is not u p to
410 // date, so it must not use the layoutObject to determine focusability. 413 // date, so it must not use the layoutObject to determine focusability.
411 virtual bool supportsFocus() const; 414 virtual bool supportsFocus() const;
412 // isFocusable(), isKeyboardFocusable(), and isMouseFocusable() check 415 // isFocusable(), isKeyboardFocusable(), and isMouseFocusable() check
413 // whether the element can actually be focused. Callers should ensure 416 // whether the element can actually be focused. Callers should ensure
414 // ComputedStyle is up to date; 417 // ComputedStyle is up to date;
415 // e.g. by calling Document::updateLayoutTreeIgnorePendingStylesheets(). 418 // e.g. by calling Document::updateLayoutTreeIgnorePendingStylesheets().
416 bool isFocusable() const; 419 bool isFocusable() const;
(...skipping 531 matching lines...) Expand 10 before | Expand all | Expand 10 after
948 static RawPtr<T> create(const QualifiedName&, Document&) 951 static RawPtr<T> create(const QualifiedName&, Document&)
949 #define DEFINE_ELEMENT_FACTORY_WITH_TAGNAME(T) \ 952 #define DEFINE_ELEMENT_FACTORY_WITH_TAGNAME(T) \
950 RawPtr<T> T::create(const QualifiedName& tagName, Document& document) \ 953 RawPtr<T> T::create(const QualifiedName& tagName, Document& document) \
951 { \ 954 { \
952 return new T(tagName, document); \ 955 return new T(tagName, document); \
953 } 956 }
954 957
955 } // namespace blink 958 } // namespace blink
956 959
957 #endif // Element_h 960 #endif // Element_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698