| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All rights reserv
ed. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All rights reserv
ed. |
| 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 254 { | 254 { |
| 255 m_textAutosizingFontScaleFactor = fontScaleFactor; | 255 m_textAutosizingFontScaleFactor = fontScaleFactor; |
| 256 | 256 |
| 257 // FIXME: I wonder if this needs to traverse frames like in WebViewImpl::res
ize, or whether there is only one document per Settings instance? | 257 // FIXME: I wonder if this needs to traverse frames like in WebViewImpl::res
ize, or whether there is only one document per Settings instance? |
| 258 for (Frame* frame = m_page->mainFrame(); frame; frame = frame->tree()->trave
rseNext()) | 258 for (Frame* frame = m_page->mainFrame(); frame; frame = frame->tree()->trave
rseNext()) |
| 259 frame->document()->textAutosizer()->recalculateMultipliers(); | 259 frame->document()->textAutosizer()->recalculateMultipliers(); |
| 260 | 260 |
| 261 m_page->setNeedsRecalcStyleInAllFrames(); | 261 m_page->setNeedsRecalcStyleInAllFrames(); |
| 262 } | 262 } |
| 263 | 263 |
| 264 void Settings::setResolutionOverride(const IntSize& densityPerInchOverride) | |
| 265 { | |
| 266 if (m_resolutionDensityPerInchOverride == densityPerInchOverride) | |
| 267 return; | |
| 268 | |
| 269 m_resolutionDensityPerInchOverride = densityPerInchOverride; | |
| 270 m_page->setNeedsRecalcStyleInAllFrames(); | |
| 271 } | |
| 272 | |
| 273 void Settings::setMediaTypeOverride(const String& mediaTypeOverride) | 264 void Settings::setMediaTypeOverride(const String& mediaTypeOverride) |
| 274 { | 265 { |
| 275 if (m_mediaTypeOverride == mediaTypeOverride) | 266 if (m_mediaTypeOverride == mediaTypeOverride) |
| 276 return; | 267 return; |
| 277 | 268 |
| 278 m_mediaTypeOverride = mediaTypeOverride; | 269 m_mediaTypeOverride = mediaTypeOverride; |
| 279 | 270 |
| 280 Frame* mainFrame = m_page->mainFrame(); | 271 Frame* mainFrame = m_page->mainFrame(); |
| 281 ASSERT(mainFrame); | 272 ASSERT(mainFrame); |
| 282 FrameView* view = mainFrame->view(); | 273 FrameView* view = mainFrame->view(); |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 375 { | 366 { |
| 376 gUsesOverlayScrollbars = flag; | 367 gUsesOverlayScrollbars = flag; |
| 377 } | 368 } |
| 378 | 369 |
| 379 bool Settings::usesOverlayScrollbars() | 370 bool Settings::usesOverlayScrollbars() |
| 380 { | 371 { |
| 381 return gUsesOverlayScrollbars; | 372 return gUsesOverlayScrollbars; |
| 382 } | 373 } |
| 383 | 374 |
| 384 } // namespace WebCore | 375 } // namespace WebCore |
| OLD | NEW |