Changeset 78715 in webkit
- Timestamp:
- Feb 16, 2011 9:12:38 AM (13 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r78714 r78715 1 2011-02-16 Mario Sanchez Prada <msanchez@igalia.com> 2 3 Reviewed by Martin Robinson. 4 5 [GTK] events missing when a document is (re)loaded 6 https://bugs.webkit.org/show_bug.cgi?id=25831 7 8 Added new layout test to check the right signals are emitted. 9 10 * platform/gtk/accessibility/document-reload-events-expected.txt: Added. 11 * platform/gtk/accessibility/document-reload-events.html: Added. 12 1 13 2011-02-16 Nikolas Zimmermann <nzimmermann@rim.com> 2 14 -
trunk/Source/WebCore/ChangeLog
r78713 r78715 1 2011-02-16 Mario Sanchez Prada <msanchez@igalia.com> 2 3 Reviewed by Martin Robinson. 4 5 [GTK] events missing when a document is (re)loaded 6 https://bugs.webkit.org/show_bug.cgi?id=25831 7 8 Make sure webArea returns a proper name and that a signal 9 'state-change::defunct' is emitted when detaching the wrapper. 10 11 Test: platform/gtk/accessibility/document-reload-events.html 12 13 * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp: 14 (webkit_accessible_get_name): Returns the current document's title 15 as fallback mechanism for webArea objects. 16 (webkit_accessible_detach): Emit 'state-change::defunct' function 17 as soon as the wrapper is detached from the related core object. 18 1 19 2011-02-15 Nikolas Zimmermann <nzimmermann@rim.com> 2 20 -
trunk/Source/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
r78349 r78715 176 176 } 177 177 178 // Try text under the node 178 // Try text under the node. 179 179 String textUnder = renderObject->textUnderElement(); 180 180 if (textUnder.length()) … … 190 190 return returnString(alt); 191 191 } 192 } 193 194 // Fallback for the webArea object: just return the document's title. 195 if (renderObject->isWebArea()) { 196 Document* document = coreObject->document(); 197 if (document) 198 return returnString(document->title()); 192 199 } 193 200 … … 2465 2472 ASSERT(accessible->m_object); 2466 2473 2474 if (core(accessible)->roleValue() == WebAreaRole) 2475 g_signal_emit_by_name(accessible, "state-change", "defunct", true); 2476 2467 2477 // We replace the WebCore AccessibilityObject with a fallback object that 2468 2478 // provides default implementations to avoid repetitive null-checking after -
trunk/Source/WebKit/gtk/ChangeLog
r78620 r78715 1 2011-02-16 Mario Sanchez Prada <msanchez@igalia.com> 2 3 Reviewed by Martin Robinson. 4 5 [GTK] events missing when a document is (re)loaded 6 https://bugs.webkit.org/show_bug.cgi?id=25831 7 8 Emit the right signals when reloading a document. 9 10 * WebCoreSupport/FrameLoaderClientGtk.cpp: 11 (WebKit::notifyAccessibilityStatus): New function, to make sure 12 the signals involved in reloading a document are properly emitted. 13 (WebKit::notifyStatus): Also notify accessibility if enabled. 14 1 15 2011-02-15 Kenneth Russell <kbr@google.com> 2 16 -
trunk/Source/WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp
r78349 r78715 26 26 #include "FrameLoaderClientGtk.h" 27 27 28 #include "AXObjectCache.h" 29 #include "AccessibilityObject.h" 28 30 #include "ArchiveResource.h" 29 31 #include "CachedFrame.h" … … 56 58 #include "ProgressTracker.h" 57 59 #include "RenderPart.h" 60 #include "RenderView.h" 58 61 #include "ResourceHandle.h" 59 62 #include "ResourceRequest.h" … … 223 226 } 224 227 228 static void notifyAccessibilityStatus(WebKitWebFrame* frame, WebKitLoadStatus loadStatus) 229 { 230 if (loadStatus != WEBKIT_LOAD_PROVISIONAL 231 && loadStatus != WEBKIT_LOAD_FAILED 232 && loadStatus != WEBKIT_LOAD_FINISHED) 233 return; 234 235 WebKitWebFramePrivate* priv = frame->priv; 236 if (!priv->coreFrame || !priv->coreFrame->document()) 237 return; 238 239 RenderView* contentRenderer = priv->coreFrame->contentRenderer(); 240 if (!contentRenderer) 241 return; 242 243 AXObjectCache* axObjectCache = priv->coreFrame->document()->axObjectCache(); 244 if (!axObjectCache) 245 return; 246 247 AccessibilityObject* coreAxObject = axObjectCache->getOrCreate(contentRenderer); 248 if (!coreAxObject) 249 return; 250 251 AtkObject* axObject = coreAxObject->wrapper(); 252 if (!axObject || !ATK_IS_DOCUMENT(axObject)) 253 return; 254 255 switch (loadStatus) { 256 case WEBKIT_LOAD_PROVISIONAL: 257 g_signal_emit_by_name(axObject, "state-change", "busy", true); 258 if (core(frame)->loader()->loadType() == FrameLoadTypeReload) 259 g_signal_emit_by_name(axObject, "reload"); 260 break; 261 case WEBKIT_LOAD_FAILED: 262 g_signal_emit_by_name(axObject, "load-stopped"); 263 g_signal_emit_by_name(axObject, "state-change", "busy", false); 264 break; 265 case WEBKIT_LOAD_FINISHED: 266 g_signal_emit_by_name(axObject, "load-complete"); 267 g_signal_emit_by_name(axObject, "state-change", "busy", false); 268 default: 269 break; 270 } 271 } 272 225 273 static void notifyStatus(WebKitWebFrame* frame, WebKitLoadStatus loadStatus) 226 274 { … … 232 280 webView->priv->loadStatus = loadStatus; 233 281 g_object_notify(G_OBJECT(webView), "load-status"); 282 283 if (AXObjectCache::accessibilityEnabled()) 284 notifyAccessibilityStatus(frame, loadStatus); 234 285 } 235 286 }
Note: See TracChangeset
for help on using the changeset viewer.