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

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

Issue 23187005: [DevTools] Use device metrics emulation implemented in content. (Closed) Base URL: svn://svn.chromium.org/blink/trunk/
Patch Set: Reupload Created 7 years, 2 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
291 void didFail(const WebCore::ResourceError&, bool wasProvisional); 291 void didFail(const WebCore::ResourceError&, bool wasProvisional);
292 292
293 // Sets whether the WebFrameImpl allows its document to be scrolled. 293 // Sets whether the WebFrameImpl allows its document to be scrolled.
294 // If the parameter is true, allow the document to be scrolled. 294 // If the parameter is true, allow the document to be scrolled.
295 // Otherwise, disallow scrolling. 295 // Otherwise, disallow scrolling.
296 void setCanHaveScrollbars(bool); 296 void setCanHaveScrollbars(bool);
297 297
298 WebFrameClient* client() const { return m_client; } 298 WebFrameClient* client() const { return m_client; }
299 void setClient(WebFrameClient* client) { m_client = client; } 299 void setClient(WebFrameClient* client) { m_client = client; }
300 300
301 void setInputEventsScaleFactorForEmulation(float);
302
301 static void selectWordAroundPosition(WebCore::Frame*, WebCore::VisiblePositi on); 303 static void selectWordAroundPosition(WebCore::Frame*, WebCore::VisiblePositi on);
302 304
303 private: 305 private:
304 class DeferredScopeStringMatches; 306 class DeferredScopeStringMatches;
305 friend class DeferredScopeStringMatches; 307 friend class DeferredScopeStringMatches;
306 friend class FrameLoaderClientImpl; 308 friend class FrameLoaderClientImpl;
307 309
308 struct FindMatch { 310 struct FindMatch {
309 RefPtr<WebCore::Range> m_range; 311 RefPtr<WebCore::Range> m_range;
310 312
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 // Valid between calls to BeginPrint() and EndPrint(). Containts the print 490 // Valid between calls to BeginPrint() and EndPrint(). Containts the print
489 // information. Is used by PrintPage(). 491 // information. Is used by PrintPage().
490 OwnPtr<ChromePrintContext> m_printContext; 492 OwnPtr<ChromePrintContext> m_printContext;
491 493
492 // The identifier of this frame. 494 // The identifier of this frame.
493 long long m_identifier; 495 long long m_identifier;
494 496
495 // Ensure we don't overwrite valid history data during same document loads 497 // Ensure we don't overwrite valid history data during same document loads
496 // from HistoryItems 498 // from HistoryItems
497 bool m_inSameDocumentHistoryLoad; 499 bool m_inSameDocumentHistoryLoad;
500
501 // Stores the additional input evetns scale when device metrics emulation is enabled.
502 float m_inputEventsScaleFactorForEmulation;
498 }; 503 };
499 504
500 inline WebFrameImpl* toWebFrameImpl(WebFrame* webFrame) 505 inline WebFrameImpl* toWebFrameImpl(WebFrame* webFrame)
501 { 506 {
502 return static_cast<WebFrameImpl*>(webFrame); 507 return static_cast<WebFrameImpl*>(webFrame);
503 } 508 }
504 509
505 inline const WebFrameImpl* toWebFrameImpl(const WebFrame* webFrame) 510 inline const WebFrameImpl* toWebFrameImpl(const WebFrame* webFrame)
506 { 511 {
507 return static_cast<const WebFrameImpl*>(webFrame); 512 return static_cast<const WebFrameImpl*>(webFrame);
508 } 513 }
509 514
510 // This will catch anyone doing an unnecessary cast. 515 // This will catch anyone doing an unnecessary cast.
511 void toWebFrameImpl(const WebFrameImpl*); 516 void toWebFrameImpl(const WebFrameImpl*);
512 517
513 } // namespace WebKit 518 } // namespace WebKit
514 519
515 #endif 520 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698