diff options
Diffstat (limited to 'fpdfsdk/pdfwindow/cpwl_special_button.cpp')
-rw-r--r-- | fpdfsdk/pdfwindow/cpwl_special_button.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/fpdfsdk/pdfwindow/cpwl_special_button.cpp b/fpdfsdk/pdfwindow/cpwl_special_button.cpp index 743565f0dc..da91da3ecb 100644 --- a/fpdfsdk/pdfwindow/cpwl_special_button.cpp +++ b/fpdfsdk/pdfwindow/cpwl_special_button.cpp @@ -18,13 +18,8 @@ CFX_ByteString CPWL_PushButton::GetClassName() const { } CFX_FloatRect CPWL_PushButton::GetFocusRect() const { - CFX_FloatRect rect = GetWindowRect(); - if (!rect.IsEmpty()) { - rect.Deflate(static_cast<float>(GetBorderWidth()), - static_cast<float>(GetBorderWidth())); - rect.Normalize(); - } - return rect; + return GetWindowRect().GetDeflated(static_cast<float>(GetBorderWidth()), + static_cast<float>(GetBorderWidth())); } CPWL_CheckBox::CPWL_CheckBox() : m_bChecked(false) {} |