| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 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 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 #include "wtf/PtrUtil.h" | 54 #include "wtf/PtrUtil.h" |
| 55 | 55 |
| 56 namespace blink { | 56 namespace blink { |
| 57 | 57 |
| 58 ExternalPopupMenu::ExternalPopupMenu(LocalFrame& frame, | 58 ExternalPopupMenu::ExternalPopupMenu(LocalFrame& frame, |
| 59 HTMLSelectElement& ownerElement, | 59 HTMLSelectElement& ownerElement, |
| 60 WebViewImpl& webView) | 60 WebViewImpl& webView) |
| 61 : m_ownerElement(ownerElement), | 61 : m_ownerElement(ownerElement), |
| 62 m_localFrame(frame), | 62 m_localFrame(frame), |
| 63 m_webView(webView), | 63 m_webView(webView), |
| 64 m_dispatchEventTimer(this, &ExternalPopupMenu::dispatchEvent), | 64 m_dispatchEventTimer( |
| 65 TaskRunnerHelper::get(TaskType::UnspecedTimer, &frame), |
| 66 this, |
| 67 &ExternalPopupMenu::dispatchEvent), |
| 65 m_webExternalPopupMenu(0) {} | 68 m_webExternalPopupMenu(0) {} |
| 66 | 69 |
| 67 ExternalPopupMenu::~ExternalPopupMenu() {} | 70 ExternalPopupMenu::~ExternalPopupMenu() {} |
| 68 | 71 |
| 69 DEFINE_TRACE(ExternalPopupMenu) { | 72 DEFINE_TRACE(ExternalPopupMenu) { |
| 70 visitor->trace(m_ownerElement); | 73 visitor->trace(m_ownerElement); |
| 71 visitor->trace(m_localFrame); | 74 visitor->trace(m_localFrame); |
| 72 PopupMenu::trace(visitor); | 75 PopupMenu::trace(visitor); |
| 73 } | 76 } |
| 74 | 77 |
| (...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 301 if (ownerElement.itemIsDisplayNone(*items[i])) | 304 if (ownerElement.itemIsDisplayNone(*items[i])) |
| 302 continue; | 305 continue; |
| 303 if (popupMenuItemIndex == i) | 306 if (popupMenuItemIndex == i) |
| 304 return indexTracker; | 307 return indexTracker; |
| 305 ++indexTracker; | 308 ++indexTracker; |
| 306 } | 309 } |
| 307 return -1; | 310 return -1; |
| 308 } | 311 } |
| 309 | 312 |
| 310 } // namespace blink | 313 } // namespace blink |
| OLD | NEW |