1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 20:07:34 +00:00

Everywhere: Rename {Deprecated => Byte}String

This commit un-deprecates DeprecatedString, and repurposes it as a byte
string.
As the null state has already been removed, there are no other
particularly hairy blockers in repurposing this type as a byte string
(what it _really_ is).

This commit is auto-generated:
  $ xs=$(ack -l \bDeprecatedString\b\|deprecated_string AK Userland \
    Meta Ports Ladybird Tests Kernel)
  $ perl -pie 's/\bDeprecatedString\b/ByteString/g;
    s/deprecated_string/byte_string/g' $xs
  $ clang-format --style=file -i \
    $(git diff --name-only | grep \.cpp\|\.h)
  $ gn format $(git ls-files '*.gn' '*.gni')
This commit is contained in:
Ali Mohammad Pur 2023-12-16 17:49:34 +03:30 committed by Ali Mohammad Pur
parent 38d62563b3
commit 5e1499d104
1615 changed files with 10257 additions and 10257 deletions

View file

@ -7,7 +7,7 @@
#pragma once
#include <AK/DeprecatedString.h>
#include <AK/ByteString.h>
#include <LibCore/ElapsedTimer.h>
#include <LibCore/Notifier.h>
#include <LibCore/Timer.h>
@ -57,7 +57,7 @@ public:
bool has_selection() const;
bool selection_contains(const VT::Position&) const;
DeprecatedString selected_text() const;
ByteString selected_text() const;
VT::Range normalized_selection() const { return m_selection.normalized(); }
void set_selection(const VT::Range& selection);
VT::Position buffer_position_at(Gfx::IntPoint) const;
@ -103,7 +103,7 @@ public:
virtual void set_cursor_shape(CursorShape) override;
static Optional<VT::CursorShape> parse_cursor_shape(StringView);
static DeprecatedString stringify_cursor_shape(VT::CursorShape);
static ByteString stringify_cursor_shape(VT::CursorShape);
private:
TerminalWidget(int ptm_fd, bool automatic_size_policy);
@ -136,7 +136,7 @@ private:
virtual void emit(u8 const*, size_t) override;
// ^GUI::Clipboard::ClipboardClient
virtual void clipboard_content_did_change(DeprecatedString const&) override { update_paste_action(); }
virtual void clipboard_content_did_change(ByteString const&) override { update_paste_action(); }
void send_non_user_input(ReadonlyBytes);
@ -167,21 +167,21 @@ private:
VT::Range m_selection;
DeprecatedString m_hovered_href;
Optional<DeprecatedString> m_hovered_href_id;
ByteString m_hovered_href;
Optional<ByteString> m_hovered_href_id;
DeprecatedString m_active_href;
Optional<DeprecatedString> m_active_href_id;
ByteString m_active_href;
Optional<ByteString> m_active_href_id;
// Snapshot of m_hovered_href when opening a context menu for a hyperlink.
DeprecatedString m_context_menu_href;
ByteString m_context_menu_href;
Gfx::Color m_colors[256];
Gfx::Color m_default_foreground_color;
Gfx::Color m_default_background_color;
bool m_show_bold_text_as_bright { true };
DeprecatedString m_color_scheme_name;
ByteString m_color_scheme_name;
BellMode m_bell_mode { BellMode::Visible };
bool m_alt_key_held { false };