Skip to content

Commit

Permalink
Fix typo: Infinate -> Infinite
Browse files Browse the repository at this point in the history
Actually I'm testing nvim-gitsigns...
  • Loading branch information
crupest committed Oct 18, 2023
1 parent e8abfdb commit 23e5aa4
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 8 deletions.
6 changes: 1 addition & 5 deletions include/cru/platform/GraphicsBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,7 @@
#include "cru/common/Range.h"
#include "cru/common/String.h"

#include <cstdint>
#include <limits>
#include <optional>
#include <string>
#include <utility>

namespace cru::platform {
struct Size;
Expand Down Expand Up @@ -61,7 +57,7 @@ struct CRU_PLATFORM_API Size final {
explicit constexpr Size(const Point& point)
: width(point.x), height(point.y) {}

constexpr static Size Infinate() {
constexpr static Size Infinite() {
return Size{std::numeric_limits<float>::max(),
std::numeric_limits<float>::max()};
}
Expand Down
2 changes: 1 addition & 1 deletion include/cru/ui/host/WindowHost.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class CRU_UI_API WindowHost : public Object, public SelfResolvable<WindowHost> {
}

void Relayout();
void RelayoutWithSize(const Size& available_size = Size::Infinate(),
void RelayoutWithSize(const Size& available_size = Size::Infinite(),
bool set_window_size_to_fit_content = false);

void Repaint();
Expand Down
2 changes: 1 addition & 1 deletion src/ui/components/Menu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ void PopupMenu::SetPosition(const Point& position) {
}

void PopupMenu::Show() {
popup_.GetWindowHost()->RelayoutWithSize(Size::Infinate(), true);
popup_.GetWindowHost()->RelayoutWithSize(Size::Infinite(), true);
auto native_window = popup_.GetWindowHost()->GetNativeWindow();
native_window->SetVisibility(platform::gui::WindowVisibilityType::Show);
native_window->RequestFocus();
Expand Down
2 changes: 1 addition & 1 deletion src/ui/host/WindowHost.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ void WindowHost::SetLayoutPreferToFillWindow(bool value) {

void WindowHost::Relayout() {
const auto available_size =
native_window_ ? native_window_->GetClientSize() : Size::Infinate();
native_window_ ? native_window_->GetClientSize() : Size::Infinite();
RelayoutWithSize(available_size);
}

Expand Down

0 comments on commit 23e5aa4

Please sign in to comment.