no false trigger of opening project item

This commit is contained in:
WanderingPenwing 2024-03-01 21:47:11 +01:00
parent d5c5ab9dba
commit 2237384ca2
2 changed files with 2 additions and 2 deletions

2
Cargo.lock generated
View file

@ -587,7 +587,7 @@ dependencies = [
[[package]]
name = "calcifer"
version = "1.1.0"
version = "1.2.0"
dependencies = [
"arboard",
"eframe",

View file

@ -176,7 +176,7 @@ impl eframe::App for Calcifer {
}
}
if ctx.input(|i| i.key_pressed(egui::Key::Enter))
if ctx.input(|i| i.key_pressed(egui::Key::Enter)) && ctx.memory(|m| m.focus() == None)
&& self.tabs[self.selected_tab].language == PROJECT_EXTENSION
{
self.project_content.item_window.visible = true;