1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-31 05:40:03 -04:00

Replace all http code in epi/eframe/egui_glium/egui_web with ehttp (#697)

I've extracted all the http request code and turned it
into its own crate at <https://github.com/emilk/ehttp>.

There was never a reason for the HTTP request library to be part of
`eframe`. Much better to have it as its own crate!
This commit is contained in:
Emil Ernerfeldt
2021-09-03 21:04:43 +02:00
committed by GitHub
parent de1a1ba9b2
commit 9598596bdc
22 changed files with 49 additions and 330 deletions

View File

@@ -137,8 +137,6 @@ pub struct AppRunner {
prefer_dark_mode: Option<bool>,
last_save_time: f64,
screen_reader: crate::screen_reader::ScreenReader,
#[cfg(feature = "http")]
http: Arc<http::WebHttp>,
pub(crate) last_text_cursor_pos: Option<egui::Pos2>,
}
@@ -165,8 +163,6 @@ impl AppRunner {
prefer_dark_mode,
last_save_time: now_sec(),
screen_reader: Default::default(),
#[cfg(feature = "http")]
http: Arc::new(http::WebHttp {}),
last_text_cursor_pos: None,
};
@@ -175,8 +171,6 @@ impl AppRunner {
let mut frame = epi::backend::FrameBuilder {
info: runner.integration_info(),
tex_allocator: runner.web_backend.painter.as_tex_allocator(),
#[cfg(feature = "http")]
http: runner.http.clone(),
output: &mut app_output,
repaint_signal: runner.needs_repaint.clone(),
}
@@ -247,8 +241,6 @@ impl AppRunner {
let mut frame = epi::backend::FrameBuilder {
info: self.integration_info(),
tex_allocator: self.web_backend.painter.as_tex_allocator(),
#[cfg(feature = "http")]
http: self.http.clone(),
output: &mut app_output,
repaint_signal: self.needs_repaint.clone(),
}