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 20 matching lines...) Expand all Loading... |
31 #include "config.h" | 31 #include "config.h" |
32 #include "ExternalPopupMenu.h" | 32 #include "ExternalPopupMenu.h" |
33 | 33 |
34 #include "WebExternalPopupMenu.h" | 34 #include "WebExternalPopupMenu.h" |
35 #include "WebMenuItemInfo.h" | 35 #include "WebMenuItemInfo.h" |
36 #include "WebPopupMenuInfo.h" | 36 #include "WebPopupMenuInfo.h" |
37 #include "WebViewClient.h" | 37 #include "WebViewClient.h" |
38 #include "core/page/Frame.h" | 38 #include "core/page/Frame.h" |
39 #include "core/page/FrameView.h" | 39 #include "core/page/FrameView.h" |
40 #include "core/platform/PopupMenuClient.h" | 40 #include "core/platform/PopupMenuClient.h" |
41 #include "core/platform/graphics/FloatQuad.h" | 41 #include "platform/geometry/FloatQuad.h" |
42 #include "core/platform/graphics/IntPoint.h" | 42 #include "platform/geometry/IntPoint.h" |
43 #include "core/platform/text/TextDirection.h" | 43 #include "platform/text/TextDirection.h" |
44 #include "public/platform/WebVector.h" | 44 #include "public/platform/WebVector.h" |
45 | 45 |
46 using namespace WebCore; | 46 using namespace WebCore; |
47 | 47 |
48 namespace WebKit { | 48 namespace WebKit { |
49 | 49 |
50 ExternalPopupMenu::ExternalPopupMenu(Frame& frame, PopupMenuClient* popupMenuCli
ent, WebViewClient* webViewClient) | 50 ExternalPopupMenu::ExternalPopupMenu(Frame& frame, PopupMenuClient* popupMenuCli
ent, WebViewClient* webViewClient) |
51 : m_popupMenuClient(popupMenuClient) | 51 : m_popupMenuClient(popupMenuClient) |
52 , m_frameView(frame.view()) | 52 , m_frameView(frame.view()) |
53 , m_webViewClient(webViewClient) | 53 , m_webViewClient(webViewClient) |
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
186 | 186 |
187 info->itemHeight = m_popupMenuClient->menuStyle().font().fontMetrics().heigh
t(); | 187 info->itemHeight = m_popupMenuClient->menuStyle().font().fontMetrics().heigh
t(); |
188 info->itemFontSize = static_cast<int>(m_popupMenuClient->menuStyle().font().
size()); | 188 info->itemFontSize = static_cast<int>(m_popupMenuClient->menuStyle().font().
size()); |
189 info->selectedIndex = m_popupMenuClient->selectedIndex(); | 189 info->selectedIndex = m_popupMenuClient->selectedIndex(); |
190 info->rightAligned = m_popupMenuClient->menuStyle().textDirection() == WebCo
re::RTL; | 190 info->rightAligned = m_popupMenuClient->menuStyle().textDirection() == WebCo
re::RTL; |
191 info->allowMultipleSelection = m_popupMenuClient->multiple(); | 191 info->allowMultipleSelection = m_popupMenuClient->multiple(); |
192 info->items.swap(items); | 192 info->items.swap(items); |
193 } | 193 } |
194 | 194 |
195 } | 195 } |
OLD | NEW |