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

Side by Side Diff: Source/core/html/HTMLDocument.cpp

Issue 17585006: Remove HTMLDocument.width and height properties (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix device metrics test with Internals API Created 7 years, 6 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
« no previous file with comments | « Source/core/html/HTMLDocument.h ('k') | Source/core/html/HTMLDocument.idl » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserv ed. 4 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserv ed.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 : Document(frame, url, HTMLDocumentClass | extendedDocumentClasses) 70 : Document(frame, url, HTMLDocumentClass | extendedDocumentClasses)
71 { 71 {
72 ScriptWrappable::init(this); 72 ScriptWrappable::init(this);
73 clearXMLVersion(); 73 clearXMLVersion();
74 } 74 }
75 75
76 HTMLDocument::~HTMLDocument() 76 HTMLDocument::~HTMLDocument()
77 { 77 {
78 } 78 }
79 79
80 int HTMLDocument::width()
81 {
82 updateLayoutIgnorePendingStylesheets();
83 FrameView* frameView = view();
84 return frameView ? frameView->contentsWidth() : 0;
85 }
86
87 int HTMLDocument::height()
88 {
89 updateLayoutIgnorePendingStylesheets();
90 FrameView* frameView = view();
91 return frameView ? frameView->contentsHeight() : 0;
92 }
93
94 String HTMLDocument::dir() 80 String HTMLDocument::dir()
95 { 81 {
96 HTMLElement* b = body(); 82 HTMLElement* b = body();
97 if (!b) 83 if (!b)
98 return String(); 84 return String();
99 return b->getAttribute(dirAttr); 85 return b->getAttribute(dirAttr);
100 } 86 }
101 87
102 void HTMLDocument::setDir(const String& value) 88 void HTMLDocument::setDir(const String& value)
103 { 89 {
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 } 350 }
365 351
366 void HTMLDocument::clear() 352 void HTMLDocument::clear()
367 { 353 {
368 // FIXME: This does nothing, and that seems unlikely to be correct. 354 // FIXME: This does nothing, and that seems unlikely to be correct.
369 // We've long had a comment saying that IE doesn't support this. 355 // We've long had a comment saying that IE doesn't support this.
370 // But I do see it in the documentation for Mozilla. 356 // But I do see it in the documentation for Mozilla.
371 } 357 }
372 358
373 } 359 }
OLDNEW
« no previous file with comments | « Source/core/html/HTMLDocument.h ('k') | Source/core/html/HTMLDocument.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698