OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * Copyright (C) 2013 Apple Inc. All rights reserved. | 3 * Copyright (C) 2013 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
138 | 138 |
139 InternalSettings::~InternalSettings() | 139 InternalSettings::~InternalSettings() |
140 { | 140 { |
141 } | 141 } |
142 | 142 |
143 InternalSettings::InternalSettings(Page& page) | 143 InternalSettings::InternalSettings(Page& page) |
144 : InternalSettingsGenerated(&page) | 144 : InternalSettingsGenerated(&page) |
145 , m_page(&page) | 145 , m_page(&page) |
146 , m_backup(&page.settings()) | 146 , m_backup(&page.settings()) |
147 { | 147 { |
148 ScriptWrappable::init(this); | |
149 } | 148 } |
150 | 149 |
151 void InternalSettings::resetToConsistentState() | 150 void InternalSettings::resetToConsistentState() |
152 { | 151 { |
153 page()->setPageScaleFactor(1, IntPoint(0, 0)); | 152 page()->setPageScaleFactor(1, IntPoint(0, 0)); |
154 | 153 |
155 m_backup.restoreTo(settings()); | 154 m_backup.restoreTo(settings()); |
156 m_backup = Backup(settings()); | 155 m_backup = Backup(settings()); |
157 m_backup.m_originalTextAutosizingEnabled = settings()->textAutosizingEnabled
(); | 156 m_backup.m_originalTextAutosizingEnabled = settings()->textAutosizingEnabled
(); |
158 | 157 |
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
435 hoverType = HoverTypeOnDemand; | 434 hoverType = HoverTypeOnDemand; |
436 else if (token == "hover") | 435 else if (token == "hover") |
437 hoverType = HoverTypeHover; | 436 hoverType = HoverTypeHover; |
438 else | 437 else |
439 exceptionState.throwDOMException(SyntaxError, "The hover type token ('"
+ token + ")' is invalid."); | 438 exceptionState.throwDOMException(SyntaxError, "The hover type token ('"
+ token + ")' is invalid."); |
440 | 439 |
441 settings()->setPrimaryHoverType(hoverType); | 440 settings()->setPrimaryHoverType(hoverType); |
442 } | 441 } |
443 | 442 |
444 } | 443 } |
OLD | NEW |