Commit 30fbf448 authored by kevino@webkit.org's avatar kevino@webkit.org

Reviewed by Kevin Ollivier.

        
Add a function for resetting the zoom factor to 1.0.
        
https://bugs.webkit.org/show_bug.cgi?id=25447


git-svn-id: svn://svn.chromium.org/blink/trunk@42931 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 7b22c65b
2009-04-28 Kevin Watters <kevinwatters@gmail.com>
Reviewed by Kevin Ollivier.
Add a function for resetting the zoom factor to 1.0.
https://bugs.webkit.org/show_bug.cgi?id=25447
* WebFrame.cpp:
(wxWebFrame::ResetTextSize):
* WebFrame.h:
* WebView.cpp:
(wxWebView::ResetTextSize):
* WebView.h:
2009-04-24 Kevin Ollivier <kevino@theolliviers.com> 2009-04-24 Kevin Ollivier <kevino@theolliviers.com>
wx build fix. Switching JSCore from a static lib to a dynamic lib wx build fix. Switching JSCore from a static lib to a dynamic lib
......
...@@ -308,6 +308,13 @@ void wxWebFrame::DecreaseTextSize() ...@@ -308,6 +308,13 @@ void wxWebFrame::DecreaseTextSize()
} }
} }
void wxWebFrame::ResetTextSize()
{
m_textMagnifier = 1.0;
if (m_impl->frame)
m_impl->frame->setZoomFactor(m_textMagnifier, true);
}
void wxWebFrame::MakeEditable(bool enable) void wxWebFrame::MakeEditable(bool enable)
{ {
m_isEditable = enable; m_isEditable = enable;
......
...@@ -143,6 +143,7 @@ public: ...@@ -143,6 +143,7 @@ public:
void IncreaseTextSize(); void IncreaseTextSize();
bool CanDecreaseTextSize() const; bool CanDecreaseTextSize() const;
void DecreaseTextSize(); void DecreaseTextSize();
void ResetTextSize();
void MakeEditable(bool enable); void MakeEditable(bool enable);
bool IsEditable() const { return m_isEditable; } bool IsEditable() const { return m_isEditable; }
......
...@@ -465,6 +465,12 @@ void wxWebView::DecreaseTextSize() ...@@ -465,6 +465,12 @@ void wxWebView::DecreaseTextSize()
m_mainFrame->DecreaseTextSize(); m_mainFrame->DecreaseTextSize();
} }
void wxWebView::ResetTextSize()
{
if (m_mainFrame)
m_mainFrame->ResetTextSize();
}
void wxWebView::MakeEditable(bool enable) void wxWebView::MakeEditable(bool enable)
{ {
m_isEditable = enable; m_isEditable = enable;
......
...@@ -138,6 +138,7 @@ public: ...@@ -138,6 +138,7 @@ public:
void IncreaseTextSize(); void IncreaseTextSize();
bool CanDecreaseTextSize() const; bool CanDecreaseTextSize() const;
void DecreaseTextSize(); void DecreaseTextSize();
void ResetTextSize();
void MakeEditable(bool enable); void MakeEditable(bool enable);
bool IsEditable() const { return m_isEditable; } bool IsEditable() const { return m_isEditable; }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment