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

Side by Side Diff: WebCore/html/HTMLFrameElementBase.cpp

Issue 2177001: Merge 58961 - Reviewed by Adele Peterson.... (Closed) Base URL: svn://chrome-svn/chrome/branches/WebKit/375/
Patch Set: Created 10 years, 7 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 | « WebCore/ChangeLog ('k') | no next file » | 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 * (C) 2000 Simon Hausmann (hausmann@kde.org) 4 * (C) 2000 Simon Hausmann (hausmann@kde.org)
5 * (C) 2001 Dirk Mueller (mueller@kde.org) 5 * (C) 2001 Dirk Mueller (mueller@kde.org)
6 * Copyright (C) 2004, 2006, 2008, 2009 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2006, 2008, 2009 Apple Inc. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 } 235 }
236 236
237 bool HTMLFrameElementBase::supportsFocus() const 237 bool HTMLFrameElementBase::supportsFocus() const
238 { 238 {
239 return true; 239 return true;
240 } 240 }
241 241
242 void HTMLFrameElementBase::setFocus(bool received) 242 void HTMLFrameElementBase::setFocus(bool received)
243 { 243 {
244 HTMLFrameOwnerElement::setFocus(received); 244 HTMLFrameOwnerElement::setFocus(received);
245 if (Page* page = document()->page()) 245 if (Page* page = document()->page()) {
246 page->focusController()->setFocusedFrame(received ? contentFrame() : 0); 246 if (received)
247 page->focusController()->setFocusedFrame(contentFrame());
248 else if (page->focusController()->focusedFrame() == contentFrame()) // F ocus may have already been given to another frame, don't take it away.
249 page->focusController()->setFocusedFrame(0);
250 }
247 } 251 }
248 252
249 bool HTMLFrameElementBase::isURLAttribute(Attribute *attr) const 253 bool HTMLFrameElementBase::isURLAttribute(Attribute *attr) const
250 { 254 {
251 return attr->name() == srcAttr; 255 return attr->name() == srcAttr;
252 } 256 }
253 257
254 int HTMLFrameElementBase::width() const 258 int HTMLFrameElementBase::width() const
255 { 259 {
256 if (!renderer()) 260 if (!renderer())
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 296
293 void HTMLFrameElementBase::willRemove() 297 void HTMLFrameElementBase::willRemove()
294 { 298 {
295 if (m_remainsAliveOnRemovalFromTree) 299 if (m_remainsAliveOnRemovalFromTree)
296 return; 300 return;
297 301
298 HTMLFrameOwnerElement::willRemove(); 302 HTMLFrameOwnerElement::willRemove();
299 } 303 }
300 304
301 } // namespace WebCore 305 } // namespace WebCore
OLDNEW
« no previous file with comments | « WebCore/ChangeLog ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698