Close select tag when javascript updated items.
authorRyuan Choi <ryuan.choi@samsung.com>
Wed, 5 Sep 2012 07:08:07 +0000 (16:08 +0900)
committerRyuan Choi <ryuan.choi@samsung.com>
Wed, 5 Sep 2012 07:08:07 +0000 (16:08 +0900)
[Title] Stored record was not updated after tags are detached.
[Issue#] N_SE-2911 (tizendev.org/buggs)
[Problem] After opened popup menu, device API updated items(option) and options are remained.
[Cause] WebCore does not have proper way to update items which updated.
[Solution] As temporal solution, just close popup.
           I will implement a way to update items when they changed using javascript.

Change-Id: I27f6c01d0765d921b0473f85f54658025b8560aa

Source/WebKit2/WebProcess/WebCoreSupport/WebPopupMenu.cpp

index 40bcb58..8df7809 100644 (file)
@@ -137,6 +137,17 @@ void WebPopupMenu::updateFromElement()
     int selectedIndex = m_popupClient->selectedIndex();
     WebProcess::shared().connection()->send(Messages::WebPageProxy::SetPopupMenuSelectedIndex(selectedIndex), m_page->pageID());
 #endif
+
+#if ENABLE(TIZEN_WEBKIT2_POPUP_INTERNAL)
+    // FIXME : We need more functionality to update select tag.
+    if (!m_page || !m_popupClient)
+        return;
+
+    m_popupClient->popupDidHide();
+
+    WebProcess::shared().connection()->send(Messages::WebPageProxy::HidePopupMenu(), m_page->pageID());
+    m_page->setActivePopupMenu(0);
+#endif
 }
 
 } // namespace WebKit