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

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

Issue 26251010: Reset to initial page scale in additional scenarios. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add test coverage and extra setNeedsLayout() call Created 7 years, 1 month 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 | « no previous file | Source/web/PageScaleConstraintsSet.cpp » ('j') | Source/web/WebViewImpl.cpp » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 66
67 // This should be set to true on each page load to note that the page scale 67 // This should be set to true on each page load to note that the page scale
68 // factor needs to be reset to its initial value. 68 // factor needs to be reset to its initial value.
69 void setNeedsReset(bool); 69 void setNeedsReset(bool);
70 bool needsReset() const { return m_needsReset; } 70 bool needsReset() const { return m_needsReset; }
71 71
72 // This is set when one of the inputs to finalConstraints changes. 72 // This is set when one of the inputs to finalConstraints changes.
73 bool constraintsDirty() const { return m_constraintsDirty; } 73 bool constraintsDirty() const { return m_constraintsDirty; }
74 74
75 private: 75 private:
76 WebCore::PageScaleConstraints computeConstraintsStack() const;
77
76 WebCore::PageScaleConstraints m_pageDefinedConstraints; 78 WebCore::PageScaleConstraints m_pageDefinedConstraints;
77 WebCore::PageScaleConstraints m_userAgentConstraints; 79 WebCore::PageScaleConstraints m_userAgentConstraints;
78 WebCore::PageScaleConstraints m_finalConstraints; 80 WebCore::PageScaleConstraints m_finalConstraints;
79 81
80 int m_lastContentsWidth; 82 int m_lastContentsWidth;
81 83
82 bool m_needsReset; 84 bool m_needsReset;
83 bool m_constraintsDirty; 85 bool m_constraintsDirty;
84 }; 86 };
85 87
86 } // namespace WebCore 88 } // namespace WebCore
87 89
88 #endif // PageScaleConstraintsSet_h 90 #endif // PageScaleConstraintsSet_h
OLDNEW
« no previous file with comments | « no previous file | Source/web/PageScaleConstraintsSet.cpp » ('j') | Source/web/WebViewImpl.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698