Chromium Code Reviews| 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 1948 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1959 frame()->loader()->reload(endToEnd); | 1959 frame()->loader()->reload(endToEnd); |
| 1960 } | 1960 } |
| 1961 | 1961 |
| 1962 #if ENABLE(ENCRYPTED_MEDIA_V2) | 1962 #if ENABLE(ENCRYPTED_MEDIA_V2) |
| 1963 void Internals::initializeMockCDM() | 1963 void Internals::initializeMockCDM() |
| 1964 { | 1964 { |
| 1965 CDM::registerCDMFactory(MockCDM::create, MockCDM::supportsKeySytem); | 1965 CDM::registerCDMFactory(MockCDM::create, MockCDM::supportsKeySytem); |
| 1966 } | 1966 } |
| 1967 #endif | 1967 #endif |
| 1968 | 1968 |
| 1969 PassRefPtr<ClientRect> Internals::selectionBounds(ExceptionCode& ec) | |
| 1970 { | |
| 1971 Document* document = contextDocument(); | |
| 1972 if (!document || !document->frame() || !document->frame()->selection()) { | |
| 1973 ec = INVALID_ACCESS_ERR; | |
| 1974 return ClientRect::create(); | |
|
esprehn
2013/06/12 19:25:30
return 0, the return value doesn't matter anyway,
svillar
2013/06/13 08:53:06
Good point
| |
| 1975 } | |
| 1976 | |
| 1977 return ClientRect::create(document->frame()->selection()->bounds()); | |
| 1978 } | |
| 1979 | |
| 1969 String Internals::markerTextForListItem(Element* element, ExceptionCode& ec) | 1980 String Internals::markerTextForListItem(Element* element, ExceptionCode& ec) |
| 1970 { | 1981 { |
| 1971 if (!element) { | 1982 if (!element) { |
| 1972 ec = INVALID_ACCESS_ERR; | 1983 ec = INVALID_ACCESS_ERR; |
| 1973 return String(); | 1984 return String(); |
| 1974 } | 1985 } |
| 1975 return WebCore::markerTextForListItem(element); | 1986 return WebCore::markerTextForListItem(element); |
| 1976 } | 1987 } |
| 1977 | 1988 |
| 1978 String Internals::getImageSourceURL(Element* element, ExceptionCode& ec) | 1989 String Internals::getImageSourceURL(Element* element, ExceptionCode& ec) |
| (...skipping 14 matching lines...) Expand all Loading... | |
| 1993 | 2004 |
| 1994 RenderObject* renderer = select->renderer(); | 2005 RenderObject* renderer = select->renderer(); |
| 1995 if (!renderer->isMenuList()) | 2006 if (!renderer->isMenuList()) |
| 1996 return false; | 2007 return false; |
| 1997 | 2008 |
| 1998 RenderMenuList* menuList = toRenderMenuList(renderer); | 2009 RenderMenuList* menuList = toRenderMenuList(renderer); |
| 1999 return menuList->popupIsVisible(); | 2010 return menuList->popupIsVisible(); |
| 2000 } | 2011 } |
| 2001 | 2012 |
| 2002 } | 2013 } |
| OLD | NEW |