omori locator
This commit is contained in:
61
src/main.rs
61
src/main.rs
@@ -1,3 +1,60 @@
|
||||
fn main() {
|
||||
println!("Hello, world!");
|
||||
mod omori_locator;
|
||||
|
||||
use std::{thread, time::Duration};
|
||||
|
||||
use eframe::egui;
|
||||
use egui::{RichText, ThemePreference};
|
||||
use omori_locator::get_omori_path;
|
||||
|
||||
fn main() -> anyhow::Result<()> {
|
||||
env_logger::init();
|
||||
|
||||
let options = eframe::NativeOptions {
|
||||
viewport: egui::ViewportBuilder::default()
|
||||
.with_min_inner_size([640.0, 480.0]),
|
||||
..Default::default()
|
||||
};
|
||||
|
||||
|
||||
println!("{:?}", get_omori_path().unwrap());
|
||||
|
||||
eframe::run_native("TundleBool", options, Box::new(|cc| {
|
||||
cc.egui_ctx.set_theme(ThemePreference::System);
|
||||
|
||||
Ok(Box::<Application>::default())
|
||||
})).unwrap();
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
struct Application {
|
||||
updates: u32
|
||||
}
|
||||
|
||||
impl Default for Application {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
updates: 0
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl eframe::App for Application {
|
||||
fn update(&mut self, ctx: &egui::Context, frame: &mut eframe::Frame) {
|
||||
ctx.request_repaint();
|
||||
egui::CentralPanel::default().show(ctx, |ui| {
|
||||
ui.vertical_centered(|ui| {
|
||||
ui.label(RichText::new("Welcome to BundleTool").size(32.0));
|
||||
ui.label(RichText::new(format!("{}", self.updates)).size(32.0));
|
||||
});
|
||||
self.updates += 1;
|
||||
ui.separator();
|
||||
egui::ScrollArea::vertical().max_width(300.0).auto_shrink(false).show(ui, |ui| {
|
||||
for i in 1..3000 {
|
||||
ui.add(egui::Label::new("Meow"));
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user