<rdar://problem/5621373> Added a way for the client to clear undo/redo
authoradachan@apple.com <adachan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 1 Dec 2007 00:47:47 +0000 (00:47 +0000)
committeradachan@apple.com <adachan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 1 Dec 2007 00:47:47 +0000 (00:47 +0000)
        operations from a WebView.

        Reviewed by Steve.

        * Interfaces/IWebViewPrivate.idl:
        * WebView.cpp:
        (WebView::clearUndoRedoOperations):
        * WebView.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@28266 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebKit/win/ChangeLog
WebKit/win/Interfaces/IWebViewPrivate.idl
WebKit/win/WebView.cpp
WebKit/win/WebView.h

index 639f91d573e9b4765202fb5f69f0e226ec093b6c..e1558872ac7db116dba5b87ca35e02ff565c2055 100644 (file)
@@ -1,3 +1,15 @@
+2007-11-30  Ada Chan  <adachan@apple.com>
+
+        <rdar://problem/5621373> Added a way for the client to clear undo/redo
+        operations from a WebView.
+
+        Reviewed by Steve.
+
+        * Interfaces/IWebViewPrivate.idl:
+        * WebView.cpp:
+        (WebView::clearUndoRedoOperations):
+        * WebView.h:
+
 2007-11-29  Anders Carlsson  <andersca@apple.com>
 
         Reviewed by Sam.
index 2057276359212c2328e29e4d1ce2b9980d1e79fe..feafc2505222513e0a6ae09ac773525f4574c078 100644 (file)
@@ -120,4 +120,6 @@ interface IWebViewPrivate : IUnknown
     HRESULT setInitialFocus([in] BOOL forward);
 
     HRESULT inspector([out, retval] IWebInspector**);
+
+    HRESULT clearUndoRedoOperations();
 }
index 9d07dd8061eb7241e525d11f83b41b47d1e29ba8..1822ceaeb645cf860cdd1e7ab6fee7e74b33f72d 100644 (file)
@@ -4120,6 +4120,13 @@ HRESULT STDMETHODCALLTYPE WebView::loadBackForwardListFromOtherView(
     return S_OK;
 }
 
+HRESULT STDMETHODCALLTYPE WebView::clearUndoRedoOperations()
+{
+    if (Frame* frame = m_page->focusController()->focusedOrMainFrame())
+        frame->editor()->clearUndoRedoOperations();
+    return S_OK;
+}
+
 HRESULT WebView::registerDragDrop()
 {
     ASSERT(::IsWindow(m_viewWindow));
index 36812fe93283bcd56b2c0453e961b617aabd2608..3c8d36f5fdbd11a8974ad97f6dc5870520d6f3a9 100644 (file)
@@ -618,6 +618,8 @@ public:
     virtual HRESULT STDMETHODCALLTYPE inspector(
         /* [retval][out] */ IWebInspector**);
 
+    virtual HRESULT STDMETHODCALLTYPE clearUndoRedoOperations( void);
+
     // WebView
     WebCore::Page* page();
     bool handleMouseEvent(UINT, WPARAM, LPARAM);