OLD | NEW |
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 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 // This should be set to true on each page load to note that the page scale | 68 // This should be set to true on each page load to note that the page scale |
69 // factor needs to be reset to its initial value. | 69 // factor needs to be reset to its initial value. |
70 void setNeedsReset(bool); | 70 void setNeedsReset(bool); |
71 bool needsReset() const { return m_needsReset; } | 71 bool needsReset() const { return m_needsReset; } |
72 | 72 |
73 // This is set when one of the inputs to finalConstraints changes. | 73 // This is set when one of the inputs to finalConstraints changes. |
74 bool constraintsDirty() const { return m_constraintsDirty; } | 74 bool constraintsDirty() const { return m_constraintsDirty; } |
75 | 75 |
76 void didChangeViewSize(const IntSize&); | 76 void didChangeViewSize(const IntSize&); |
77 | 77 |
78 IntSize mainFrameSize(const IntSize& contentsSize) const; | 78 IntSize mainFrameSize(int contentWidthIncludingScrollbar) const; |
79 | 79 |
80 private: | 80 private: |
81 PageScaleConstraints computeConstraintsStack() const; | 81 PageScaleConstraints computeConstraintsStack() const; |
82 | 82 |
83 PageScaleConstraints m_pageDefinedConstraints; | 83 PageScaleConstraints m_pageDefinedConstraints; |
84 PageScaleConstraints m_userAgentConstraints; | 84 PageScaleConstraints m_userAgentConstraints; |
85 PageScaleConstraints m_finalConstraints; | 85 PageScaleConstraints m_finalConstraints; |
86 | 86 |
87 int m_lastContentsWidth; | 87 int m_lastContentsWidth; |
88 IntSize m_viewSize; | 88 IntSize m_viewSize; |
89 | 89 |
90 bool m_needsReset; | 90 bool m_needsReset; |
91 bool m_constraintsDirty; | 91 bool m_constraintsDirty; |
92 }; | 92 }; |
93 | 93 |
94 } // namespace blink | 94 } // namespace blink |
95 | 95 |
96 #endif // PageScaleConstraintsSet_h | 96 #endif // PageScaleConstraintsSet_h |
OLD | NEW |