Changeset 48968 in webkit
- Timestamp:
- Oct 1, 2009 5:43:49 AM (15 years ago)
- Location:
- trunk/WebKit/qt
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKit/qt/Api/qwebpage.cpp
r48967 r48968 268 268 , inspectorIsInternalOnly(false) 269 269 , viewportSize(QSize(0, 0)) 270 , clickCausedFocus(false) 270 271 { 271 272 WebCore::InitializeLoggingChannelsIfNecessary(); … … 633 634 return; 634 635 636 RefPtr<WebCore::Node> oldNode; 637 if (page->focusController()->focusedFrame() 638 && page->focusController()->focusedFrame()->document()) 639 oldNode = page->focusController()->focusedFrame()->document()->focusedNode(); 640 635 641 if (tripleClickTimer.isActive() 636 642 && (ev->pos() - tripleClick).manhattanLength() … … 646 652 accepted = frame->eventHandler()->handleMousePressEvent(mev); 647 653 ev->setAccepted(accepted); 654 655 RefPtr<WebCore::Node> newNode; 656 if (page->focusController()->focusedFrame() 657 && page->focusController()->focusedFrame()->document()) 658 newNode = page->focusController()->focusedFrame()->document()->focusedNode(); 659 660 if (newNode && oldNode != newNode) 661 clickCausedFocus = true; 648 662 } 649 663 … … 751 765 752 766 handleClipboard(ev, ev->button()); 767 768 #if QT_VERSION >= QT_VERSION_CHECK(4, 6, 0) 769 if (view && view->testAttribute(Qt::WA_InputMethodEnabled) 770 && ev->button() == Qt::LeftButton && qApp->autoSipEnabled()) { 771 QStyle::RequestSoftwareInputPanel behavior = QStyle::RequestSoftwareInputPanel( 772 view->style()->styleHint(QStyle::SH_RequestSoftwareInputPanel)); 773 if (!clickCausedFocus || behavior == QStyle::RSIP_OnMouseClick) { 774 QEvent event(QEvent::RequestSoftwareInputPanel); 775 QApplication::sendEvent(view, &event); 776 } 777 } 778 779 clickCausedFocus = false; 780 #endif 753 781 } 754 782 -
trunk/WebKit/qt/Api/qwebpage_p.h
r48604 r48968 144 144 QBasicTimer tripleClickTimer; 145 145 146 bool clickCausedFocus; 147 146 148 #if QT_VERSION < 0x040400 147 149 bool acceptNavigationRequest(QWebFrame *frame, const QWebNetworkRequest &request, QWebPage::NavigationType type); -
trunk/WebKit/qt/ChangeLog
r48967 r48968 1 2009-10-01 Kristian Amlie <kristian.amlie@nokia.com> 2 3 Reviewed by Simon Hausmann. 4 5 Fixed software input panel support on web input elements. 6 7 Send the RequestSoftwareInputPanel event if the element supports focus 8 and the element is clicked. 9 10 * Api/qwebpage.cpp: 11 (QWebPagePrivate::QWebPagePrivate): 12 (QWebPagePrivate::mousePressEvent): 13 (QWebPagePrivate::mouseReleaseEvent): 14 * Api/qwebpage_p.h: 15 1 16 2009-10-01 Joe Ligman <joseph.ligman@nokia.com> 2 17
Note: See TracChangeset
for help on using the changeset viewer.