summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
Diffstat (limited to 'examples')
-rw-r--r--examples/pure/component/Cargo.toml1
-rw-r--r--examples/pure/component/src/main.rs8
-rw-r--r--examples/pure/counter/src/main.rs3
-rw-r--r--examples/pure/game_of_life/src/main.rs6
-rw-r--r--examples/pure/pane_grid/src/main.rs2
-rw-r--r--examples/pure/pick_list/src/main.rs4
-rw-r--r--examples/pure/todos/src/main.rs5
-rw-r--r--examples/pure/tour/src/main.rs5
8 files changed, 16 insertions, 18 deletions
diff --git a/examples/pure/component/Cargo.toml b/examples/pure/component/Cargo.toml
index a15f134f..b6c7a513 100644
--- a/examples/pure/component/Cargo.toml
+++ b/examples/pure/component/Cargo.toml
@@ -9,3 +9,4 @@ publish = false
iced = { path = "../../..", features = ["debug", "pure"] }
iced_native = { path = "../../../native" }
iced_lazy = { path = "../../../lazy", features = ["pure"] }
+iced_pure = { path = "../../../pure" }
diff --git a/examples/pure/component/src/main.rs b/examples/pure/component/src/main.rs
index ab10317f..b38d6fca 100644
--- a/examples/pure/component/src/main.rs
+++ b/examples/pure/component/src/main.rs
@@ -1,4 +1,4 @@
-use iced::pure::widget::container;
+use iced::pure::container;
use iced::pure::{Element, Sandbox};
use iced::{Length, Settings};
@@ -47,12 +47,12 @@ impl Sandbox for Component {
}
mod numeric_input {
- use iced::pure::widget::Element;
- use iced::pure::widget::{row, text, text_input};
+ use iced::pure::{button, row, text, text_input};
use iced_lazy::pure::{self, Component};
use iced_native::alignment::{self, Alignment};
use iced_native::text;
use iced_native::Length;
+ use iced_pure::Element;
pub struct NumericInput<Message> {
value: Option<u32>,
@@ -120,8 +120,6 @@ mod numeric_input {
fn view(&self, _state: &Self::State) -> Element<Event, Renderer> {
let button = |label, on_press| {
- use iced::pure::widget::button;
-
button(
text(label)
.width(Length::Fill)
diff --git a/examples/pure/counter/src/main.rs b/examples/pure/counter/src/main.rs
index 9b520347..726009df 100644
--- a/examples/pure/counter/src/main.rs
+++ b/examples/pure/counter/src/main.rs
@@ -1,5 +1,4 @@
-use iced::pure::widget::{button, column, text};
-use iced::pure::{Element, Sandbox};
+use iced::pure::{button, column, text, Element, Sandbox};
use iced::{Alignment, Settings};
pub fn main() -> iced::Result {
diff --git a/examples/pure/game_of_life/src/main.rs b/examples/pure/game_of_life/src/main.rs
index 75a0deef..f63ef41b 100644
--- a/examples/pure/game_of_life/src/main.rs
+++ b/examples/pure/game_of_life/src/main.rs
@@ -5,7 +5,7 @@ mod style;
use grid::Grid;
use iced::executor;
-use iced::pure::widget::{
+use iced::pure::{
button, checkbox, column, container, pick_list, row, slider, text,
};
use iced::pure::{Application, Element};
@@ -207,8 +207,8 @@ fn view_controls<'a>(
mod grid {
use crate::Preset;
- use iced::pure::canvas::event::{self, Event};
- use iced::pure::canvas::{
+ use iced::pure::widget::canvas::event::{self, Event};
+ use iced::pure::widget::canvas::{
self, Cache, Canvas, Cursor, Frame, Geometry, Path, Text,
};
use iced::pure::Element;
diff --git a/examples/pure/pane_grid/src/main.rs b/examples/pure/pane_grid/src/main.rs
index 6a733023..65516956 100644
--- a/examples/pure/pane_grid/src/main.rs
+++ b/examples/pure/pane_grid/src/main.rs
@@ -1,7 +1,7 @@
use iced::alignment::{self, Alignment};
use iced::executor;
use iced::keyboard;
-use iced::pure::pane_grid::{self, PaneGrid};
+use iced::pure::widget::pane_grid::{self, PaneGrid};
use iced::pure::{button, column, container, row, scrollable, text};
use iced::pure::{Application, Element};
use iced::{Color, Command, Length, Settings, Size, Subscription};
diff --git a/examples/pure/pick_list/src/main.rs b/examples/pure/pick_list/src/main.rs
index f9d55dd0..b9947107 100644
--- a/examples/pure/pick_list/src/main.rs
+++ b/examples/pure/pick_list/src/main.rs
@@ -1,6 +1,4 @@
-use iced::pure::widget::{
- column, container, pick_list, scrollable, vertical_space,
-};
+use iced::pure::{column, container, pick_list, scrollable, vertical_space};
use iced::pure::{Element, Sandbox};
use iced::{Alignment, Length, Settings};
diff --git a/examples/pure/todos/src/main.rs b/examples/pure/todos/src/main.rs
index e993c598..6a6c6300 100644
--- a/examples/pure/todos/src/main.rs
+++ b/examples/pure/todos/src/main.rs
@@ -1,8 +1,9 @@
use iced::alignment::{self, Alignment};
-use iced::pure::widget::{
+use iced::pure::widget::Text;
+use iced::pure::{
button, checkbox, column, container, row, scrollable, text, text_input,
+ Application, Element,
};
-use iced::pure::{Application, Element, Text};
use iced::window;
use iced::{Command, Font, Length, Settings};
use serde::{Deserialize, Serialize};
diff --git a/examples/pure/tour/src/main.rs b/examples/pure/tour/src/main.rs
index 7a50bcdc..a44d99f3 100644
--- a/examples/pure/tour/src/main.rs
+++ b/examples/pure/tour/src/main.rs
@@ -1,9 +1,10 @@
use iced::alignment;
-use iced::pure::widget::{
+use iced::pure::widget::{Button, Column, Container, Slider};
+use iced::pure::{
checkbox, column, container, horizontal_space, image, radio, row,
scrollable, slider, text, text_input, toggler, vertical_space,
};
-use iced::pure::{Button, Column, Container, Element, Sandbox, Slider};
+use iced::pure::{Element, Sandbox};
use iced::{Color, Length, Settings};
pub fn main() -> iced::Result {