https://git.reactos.org/?p=reactos.git;a=commitdiff;h=6d7aaaade0a4735165e8307d0d7dec3eaedf8156

commit 6d7aaaade0a4735165e8307d0d7dec3eaedf8156
Author:     Katayama Hirofumi MZ <katayama.hirofumi...@gmail.com>
AuthorDate: Tue Oct 31 11:13:54 2023 +0900
Commit:     Katayama Hirofumi MZ <katayama.hirofumi...@gmail.com>
CommitDate: Tue Oct 31 11:13:54 2023 +0900

    [MSPAINT] Delete needless ImageModel::ResetToPrevious
    
    CORE-19094
---
 base/applications/mspaint/history.cpp | 12 ------------
 base/applications/mspaint/history.h   |  1 -
 2 files changed, 13 deletions(-)

diff --git a/base/applications/mspaint/history.cpp 
b/base/applications/mspaint/history.cpp
index 283b5f0c083..22aaf6835f4 100644
--- a/base/applications/mspaint/history.cpp
+++ b/base/applications/mspaint/history.cpp
@@ -89,18 +89,6 @@ void ImageModel::Redo()
     NotifyImageChanged();
 }
 
-void ImageModel::ResetToPrevious()
-{
-    ATLTRACE("%s: %d\n", __FUNCTION__, m_currInd);
-
-    // Revert current item with previous item
-    ::DeleteObject(m_hBms[m_currInd]);
-    m_hBms[m_currInd] = CopyDIBImage(m_hBms[(m_currInd + HISTORYSIZE - 1) % 
HISTORYSIZE]);
-    ::SelectObject(m_hDrawingDC, m_hBms[m_currInd]);
-
-    NotifyImageChanged();
-}
-
 void ImageModel::ClearHistory()
 {
     for (int i = 0; i < HISTORYSIZE; ++i)
diff --git a/base/applications/mspaint/history.h 
b/base/applications/mspaint/history.h
index 093dd1c34dd..716db560a8e 100644
--- a/base/applications/mspaint/history.h
+++ b/base/applications/mspaint/history.h
@@ -21,7 +21,6 @@ public:
     BOOL CanRedo() const { return m_redoSteps > 0; }
     void PushImageForUndo();
     void PushImageForUndo(HBITMAP hbm);
-    void ResetToPrevious(void);
     void Undo(BOOL bClearRedo = FALSE);
     void Redo(void);
     void ClearHistory(void);

Reply via email to