1
0
mirror of https://github.com/emilk/egui.git synced 2026-09-01 06:10:06 -04:00

[glium] make it super easy to make an Egui app using glium

This commit is contained in:
Emil Ernerfeldt
2020-07-22 18:46:12 +02:00
parent e84412dec5
commit a14bfa0e73
4 changed files with 141 additions and 124 deletions

View File

@@ -5,10 +5,18 @@
mod painter;
pub mod persistence;
mod runner;
pub use painter::Painter;
pub use runner::*;
use glutin::event_loop::ControlFlow;
use {
clipboard::ClipboardProvider,
egui::*,
glium::glutin::{self, event::VirtualKeyCode, event_loop::ControlFlow},
};
pub use clipboard::ClipboardContext; // TODO: remove
pub fn input_to_egui(
event: glutin::event::WindowEvent,
@@ -196,12 +204,6 @@ pub fn handle_output(
.set_cursor_icon(translate_cursor(output.cursor_icon));
}
use {
clipboard::{ClipboardContext, ClipboardProvider},
egui::*,
glium::glutin::{self, event::VirtualKeyCode},
};
pub fn init_clipboard() -> Option<ClipboardContext> {
match ClipboardContext::new() {
Ok(clipboard) => Some(clipboard),