summaryrefslogtreecommitdiff
path: root/Userland/Applications/PDFViewer
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2022-12-04 18:02:33 +0000
committerAndreas Kling <kling@serenityos.org>2022-12-06 08:54:33 +0100
commit6e19ab2bbce0b113b628e6f8e9b5c0640053933e (patch)
tree372d21b2f5dcff112f5d0089559c6af5798680d4 /Userland/Applications/PDFViewer
parentf74251606d74b504a1379ebb893fdb5529054ea5 (diff)
downloadserenity-6e19ab2bbce0b113b628e6f8e9b5c0640053933e.zip
AK+Everywhere: Rename String to DeprecatedString
We have a new, improved string type coming up in AK (OOM aware, no null state), and while it's going to use UTF-8, the name UTF8String is a mouthful - so let's free up the String name by renaming the existing class. Making the old one have an annoying name will hopefully also help with quick adoption :^)
Diffstat (limited to 'Userland/Applications/PDFViewer')
-rw-r--r--Userland/Applications/PDFViewer/NumericInput.cpp4
-rw-r--r--Userland/Applications/PDFViewer/PDFViewerWidget.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/Userland/Applications/PDFViewer/NumericInput.cpp b/Userland/Applications/PDFViewer/NumericInput.cpp
index fcd5769e5c..b5290e36c3 100644
--- a/Userland/Applications/PDFViewer/NumericInput.cpp
+++ b/Userland/Applications/PDFViewer/NumericInput.cpp
@@ -70,7 +70,7 @@ void NumericInput::set_max_number(i32 number)
void NumericInput::on_focus_lost()
{
if (m_needs_text_reset) {
- set_text(String::number(m_current_number));
+ set_text(DeprecatedString::number(m_current_number));
m_needs_text_reset = false;
}
if (on_number_changed)
@@ -83,7 +83,7 @@ void NumericInput::set_current_number(i32 number, GUI::AllowCallback allow_callb
return;
m_current_number = clamp(number, m_min_number, m_max_number);
- set_text(String::number(m_current_number));
+ set_text(DeprecatedString::number(m_current_number));
if (on_number_changed && allow_callback == GUI::AllowCallback::Yes)
on_number_changed(m_current_number);
}
diff --git a/Userland/Applications/PDFViewer/PDFViewerWidget.cpp b/Userland/Applications/PDFViewer/PDFViewerWidget.cpp
index 159e367635..1af1d1e044 100644
--- a/Userland/Applications/PDFViewer/PDFViewerWidget.cpp
+++ b/Userland/Applications/PDFViewer/PDFViewerWidget.cpp
@@ -184,7 +184,7 @@ void PDFViewerWidget::initialize_toolbar(GUI::Toolbar& toolbar)
void PDFViewerWidget::open_file(Core::File& file)
{
- window()->set_title(String::formatted("{} - PDF Viewer", file.filename()));
+ window()->set_title(DeprecatedString::formatted("{} - PDF Viewer", file.filename()));
auto handle_error = [&]<typename T>(PDF::PDFErrorOr<T> maybe_error) {
if (maybe_error.is_error()) {
@@ -214,7 +214,7 @@ void PDFViewerWidget::open_file(Core::File& file)
if (handle_error(m_viewer->set_document(document)))
return;
- m_total_page_label->set_text(String::formatted("of {}", document->get_page_count()));
+ m_total_page_label->set_text(DeprecatedString::formatted("of {}", document->get_page_count()));
m_page_text_box->set_enabled(true);
m_page_text_box->set_current_number(1, GUI::AllowCallback::No);