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

Side by Side Diff: third_party/WebKit/Source/core/style/ComputedStyle.h

Issue 1690493002: Switch to LayoutThemeMobile when emulating mobile device in DevTools. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more mac compile Created 4 years, 10 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) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) 6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com)
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 338 matching lines...) Expand 10 before | Expand all | Expand 10 after
349 private: 349 private:
350 ALWAYS_INLINE ComputedStyle(); 350 ALWAYS_INLINE ComputedStyle();
351 351
352 enum InitialStyleTag { 352 enum InitialStyleTag {
353 InitialStyle 353 InitialStyle
354 }; 354 };
355 ALWAYS_INLINE explicit ComputedStyle(InitialStyleTag); 355 ALWAYS_INLINE explicit ComputedStyle(InitialStyleTag);
356 ALWAYS_INLINE ComputedStyle(const ComputedStyle&); 356 ALWAYS_INLINE ComputedStyle(const ComputedStyle&);
357 357
358 static PassRefPtr<ComputedStyle> createInitialStyle(); 358 static PassRefPtr<ComputedStyle> createInitialStyle();
359 static inline ComputedStyle* initialStyle() 359 static inline ComputedStyle* initialStyle() { return *initialStylePointer(); }
360 static inline ComputedStyle** initialStylePointer()
360 { 361 {
361 LEAK_SANITIZER_DISABLED_SCOPE; 362 LEAK_SANITIZER_DISABLED_SCOPE;
362 DEFINE_STATIC_REF(ComputedStyle, s_initialStyle, (ComputedStyle::createI nitialStyle())); 363 DEFINE_STATIC_REF(ComputedStyle, s_initialStyle, (ComputedStyle::createI nitialStyle()));
363 return s_initialStyle; 364 return &s_initialStyle;
364 } 365 }
365 366
366 public: 367 public:
367 static PassRefPtr<ComputedStyle> create(); 368 static PassRefPtr<ComputedStyle> create();
368 static PassRefPtr<ComputedStyle> createAnonymousStyleWithDisplay(const Compu tedStyle& parentStyle, EDisplay); 369 static PassRefPtr<ComputedStyle> createAnonymousStyleWithDisplay(const Compu tedStyle& parentStyle, EDisplay);
369 static PassRefPtr<ComputedStyle> clone(const ComputedStyle&); 370 static PassRefPtr<ComputedStyle> clone(const ComputedStyle&);
371 static void clearInitialStyle();
370 372
371 // Computes how the style change should be propagated down the tree. 373 // Computes how the style change should be propagated down the tree.
372 static StyleRecalcChange stylePropagationDiff(const ComputedStyle* oldStyle, const ComputedStyle* newStyle); 374 static StyleRecalcChange stylePropagationDiff(const ComputedStyle* oldStyle, const ComputedStyle* newStyle);
373 375
374 const StyleSelfAlignmentData resolvedAlignment(const ComputedStyle& parentSt yle, ItemPosition resolvedAutoPositionForLayoutObject) const; 376 const StyleSelfAlignmentData resolvedAlignment(const ComputedStyle& parentSt yle, ItemPosition resolvedAutoPositionForLayoutObject) const;
375 static ItemPosition resolveAlignment(const ComputedStyle& parentStyle, const ComputedStyle& childStyle, ItemPosition resolvedAutoPositionForLayoutObject); 377 static ItemPosition resolveAlignment(const ComputedStyle& parentStyle, const ComputedStyle& childStyle, ItemPosition resolvedAutoPositionForLayoutObject);
376 static ItemPosition resolveJustification(const ComputedStyle& parentStyle, c onst ComputedStyle& childStyle, ItemPosition resolvedAutoPositionForLayoutObject ); 378 static ItemPosition resolveJustification(const ComputedStyle& parentStyle, c onst ComputedStyle& childStyle, ItemPosition resolvedAutoPositionForLayoutObject );
377 379
378 StyleDifference visualInvalidationDiff(const ComputedStyle&) const; 380 StyleDifference visualInvalidationDiff(const ComputedStyle&) const;
379 381
(...skipping 1638 matching lines...) Expand 10 before | Expand all | Expand 10 after
2018 } 2020 }
2019 2021
2020 inline bool ComputedStyle::hasPseudoElementStyle() const 2022 inline bool ComputedStyle::hasPseudoElementStyle() const
2021 { 2023 {
2022 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK; 2024 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK;
2023 } 2025 }
2024 2026
2025 } // namespace blink 2027 } // namespace blink
2026 2028
2027 #endif // ComputedStyle_h 2029 #endif // ComputedStyle_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698