Skip to content

Commit

Permalink
[omg] Move ion/stack.h to omg.
Browse files Browse the repository at this point in the history
  • Loading branch information
MathieuNumworks authored and GabrielNumworks committed Jan 25, 2024
1 parent 7c6a780 commit 0737560
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions escher/include/escher/stack_view.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include <escher/solid_color_view.h>
#include <escher/stack_header_view.h>
#include <ion/stack.h>
#include <omg/stack.h>

namespace Escher {

Expand All @@ -16,7 +16,7 @@ class StackView : public View {
static constexpr uint8_t k_maxDepth = sizeof(Mask) * 8;

StackView(Style style, bool extendVertically,
Ion::AbstractStack<StackHeaderView>* headerViewStack);
OMG::AbstractStack<StackHeaderView>* headerViewStack);
int8_t numberOfStacks() const { return m_stackHeaderViews->length(); }
void setContentView(View* view);
void setupHeadersBorderOverlaping(bool headersOverlapHeaders,
Expand All @@ -41,7 +41,7 @@ class StackView : public View {
// Returns the index in m_stackViews for a given display index
int stackHeaderIndex(int displayIndex);

Ion::AbstractStack<StackHeaderView>* m_stackHeaderViews;
OMG::AbstractStack<StackHeaderView>* m_stackHeaderViews;
SolidColorView m_borderView;
View* m_contentView;
Style m_style;
Expand Down
6 changes: 3 additions & 3 deletions escher/include/escher/stack_view_controller.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class StackViewController : public ViewController {
protected:
StackViewController(Responder* parentResponder, StackView::Style style,
bool extendVertically,
Ion::AbstractStack<StackHeaderView>* headerViewStack);
OMG::AbstractStack<StackHeaderView>* headerViewStack);

private:
StackView m_view;
Expand Down Expand Up @@ -78,7 +78,7 @@ class CustomSizeStackViewController : public StackViewController {
public:
static_assert(Capacity <= StackView::k_maxDepth);

using Stack = Ion::Stack<StackHeaderView, Capacity>;
using Stack = OMG::Stack<StackHeaderView, Capacity>;

constexpr static int k_maxNumberOfChildren = Capacity;

Expand All @@ -99,7 +99,7 @@ class CustomSizeStackViewController : public StackViewController {
}

ViewController* m_stack[Capacity];
Ion::Stack<StackHeaderView, Capacity> m_headerViewStack;
OMG::Stack<StackHeaderView, Capacity> m_headerViewStack;
};

} // namespace Escher
Expand Down
2 changes: 1 addition & 1 deletion escher/src/stack_view.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
namespace Escher {

StackView::StackView(Style style, bool extendVertically,
Ion::AbstractStack<StackHeaderView>* headerViewStack)
OMG::AbstractStack<StackHeaderView>* headerViewStack)
: View(),
m_borderView(Palette::GrayBright),
m_contentView(nullptr),
Expand Down
2 changes: 1 addition & 1 deletion escher/src/stack_view_controller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ namespace Escher {

StackViewController::StackViewController(
Responder* parentResponder, StackView::Style style, bool extendVertically,
Ion::AbstractStack<StackHeaderView>* headerViewStack)
OMG::AbstractStack<StackHeaderView>* headerViewStack)
: ViewController(parentResponder),
m_view(style, extendVertically, headerViewStack),
m_size(1),
Expand Down
8 changes: 4 additions & 4 deletions ion/include/ion/stack.h → omg/include/omg/stack.h
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#ifndef ION_STACK_H
#define ION_STACK_H
#ifndef OMG_STACK_H
#define OMG_STACK_H

#include <assert.h>
#include <stddef.h>

namespace Ion {
namespace OMG {

// All implementations are in header to avoid having to specify templates

Expand Down Expand Up @@ -43,6 +43,6 @@ class Stack : public AbstractStack<T> {
T m_content[N];
};

} // namespace Ion
} // namespace OMG

#endif

0 comments on commit 0737560

Please sign in to comment.