Skip to content

Commit

Permalink
Show in our examples that a node ID of 0 is now OK
Browse files Browse the repository at this point in the history
  • Loading branch information
mwcampbell committed Aug 18, 2023
1 parent 2f17c4a commit 3721471
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 16 deletions.
8 changes: 4 additions & 4 deletions bindings/c/examples/sdl/hello_world.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@

const char WINDOW_TITLE[] = "Hello world";

const accesskit_node_id WINDOW_ID = 1;
const accesskit_node_id BUTTON_1_ID = 2;
const accesskit_node_id BUTTON_2_ID = 3;
const accesskit_node_id ANNOUNCEMENT_ID = 4;
const accesskit_node_id WINDOW_ID = 0;
const accesskit_node_id BUTTON_1_ID = 1;
const accesskit_node_id BUTTON_2_ID = 2;
const accesskit_node_id ANNOUNCEMENT_ID = 3;
const accesskit_node_id INITIAL_FOCUS = BUTTON_1_ID;

const accesskit_rect BUTTON_1_RECT = {20.0, 20.0, 100.0, 60.0};
Expand Down
8 changes: 4 additions & 4 deletions bindings/c/examples/windows/hello_world.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ const WCHAR CLASS_NAME[] = L"AccessKitTest";

const WCHAR WINDOW_TITLE[] = L"Hello world";

const accesskit_node_id WINDOW_ID = 1;
const accesskit_node_id BUTTON_1_ID = 2;
const accesskit_node_id BUTTON_2_ID = 3;
const accesskit_node_id ANNOUNCEMENT_ID = 4;
const accesskit_node_id WINDOW_ID = 0;
const accesskit_node_id BUTTON_1_ID = 1;
const accesskit_node_id BUTTON_2_ID = 2;
const accesskit_node_id ANNOUNCEMENT_ID = 3;
const accesskit_node_id INITIAL_FOCUS = BUTTON_1_ID;

const accesskit_rect BUTTON_1_RECT = {20.0, 20.0, 100.0, 60.0};
Expand Down
8 changes: 4 additions & 4 deletions platforms/windows/examples/hello_world.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@ static WINDOW_CLASS_ATOM: Lazy<u16> = Lazy::new(|| {

const WINDOW_TITLE: &str = "Hello world";

const WINDOW_ID: NodeId = NodeId(1);
const BUTTON_1_ID: NodeId = NodeId(2);
const BUTTON_2_ID: NodeId = NodeId(3);
const ANNOUNCEMENT_ID: NodeId = NodeId(4);
const WINDOW_ID: NodeId = NodeId(0);
const BUTTON_1_ID: NodeId = NodeId(1);
const BUTTON_2_ID: NodeId = NodeId(2);
const ANNOUNCEMENT_ID: NodeId = NodeId(3);
const INITIAL_FOCUS: NodeId = BUTTON_1_ID;

const BUTTON_1_RECT: Rect = Rect {
Expand Down
8 changes: 4 additions & 4 deletions platforms/winit/examples/simple.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ use winit::{

const WINDOW_TITLE: &str = "Hello world";

const WINDOW_ID: NodeId = NodeId(1);
const BUTTON_1_ID: NodeId = NodeId(2);
const BUTTON_2_ID: NodeId = NodeId(3);
const ANNOUNCEMENT_ID: NodeId = NodeId(4);
const WINDOW_ID: NodeId = NodeId(0);
const BUTTON_1_ID: NodeId = NodeId(1);
const BUTTON_2_ID: NodeId = NodeId(2);
const ANNOUNCEMENT_ID: NodeId = NodeId(3);
const INITIAL_FOCUS: NodeId = BUTTON_1_ID;

const BUTTON_1_RECT: Rect = Rect {
Expand Down

0 comments on commit 3721471

Please sign in to comment.