mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-10 10:01:13 +09:00
HackStudio: Add header navigation
This commit is contained in:
parent
d8a73dd979
commit
879bf3e97b
Notes:
sideshowbarker
2024-07-19 08:45:23 +09:00
Author: https://github.com/oriko1010
Commit: 879bf3e97b
Pull-request: https://github.com/SerenityOS/serenity/pull/1421
4 changed files with 95 additions and 4 deletions
|
@ -33,6 +33,7 @@
|
|||
#include <LibGfx/Font.h>
|
||||
|
||||
extern RefPtr<EditorWrapper> g_current_editor_wrapper;
|
||||
extern Function<void(String)> g_open_file;
|
||||
|
||||
EditorWrapper::EditorWrapper()
|
||||
{
|
||||
|
@ -67,6 +68,10 @@ EditorWrapper::EditorWrapper()
|
|||
m_editor->on_focus = [this] {
|
||||
g_current_editor_wrapper = this;
|
||||
};
|
||||
|
||||
m_editor->on_open = [this](String path) {
|
||||
g_open_file(path);
|
||||
};
|
||||
}
|
||||
|
||||
EditorWrapper::~EditorWrapper()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue