Skip to content

Commit

Permalink
Merge pull request #281 from AdenKoperczak/location_markers
Browse files Browse the repository at this point in the history
Add Location Markers (Part 1)
  • Loading branch information
dpaulat authored Oct 18, 2024
2 parents 72a1697 + fe93113 commit 1843f38
Show file tree
Hide file tree
Showing 25 changed files with 1,343 additions and 3 deletions.
11 changes: 11 additions & 0 deletions scwx-qt/res/textures/images/location-marker.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions scwx-qt/scwx-qt.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ set(HDR_MANAGER source/scwx/qt/manager/alert_manager.hpp
source/scwx/qt/manager/log_manager.hpp
source/scwx/qt/manager/media_manager.hpp
source/scwx/qt/manager/placefile_manager.hpp
source/scwx/qt/manager/marker_manager.hpp
source/scwx/qt/manager/position_manager.hpp
source/scwx/qt/manager/radar_product_manager.hpp
source/scwx/qt/manager/radar_product_manager_notifier.hpp
Expand All @@ -111,6 +112,7 @@ set(SRC_MANAGER source/scwx/qt/manager/alert_manager.cpp
source/scwx/qt/manager/log_manager.cpp
source/scwx/qt/manager/media_manager.cpp
source/scwx/qt/manager/placefile_manager.cpp
source/scwx/qt/manager/marker_manager.cpp
source/scwx/qt/manager/position_manager.cpp
source/scwx/qt/manager/radar_product_manager.cpp
source/scwx/qt/manager/radar_product_manager_notifier.cpp
Expand All @@ -132,6 +134,7 @@ set(HDR_MAP source/scwx/qt/map/alert_layer.hpp
source/scwx/qt/map/overlay_layer.hpp
source/scwx/qt/map/overlay_product_layer.hpp
source/scwx/qt/map/placefile_layer.hpp
source/scwx/qt/map/marker_layer.hpp
source/scwx/qt/map/radar_product_layer.hpp
source/scwx/qt/map/radar_range_layer.hpp
source/scwx/qt/map/radar_site_layer.hpp)
Expand All @@ -146,6 +149,7 @@ set(SRC_MAP source/scwx/qt/map/alert_layer.cpp
source/scwx/qt/map/overlay_layer.cpp
source/scwx/qt/map/overlay_product_layer.cpp
source/scwx/qt/map/placefile_layer.cpp
source/scwx/qt/map/marker_layer.cpp
source/scwx/qt/map/radar_product_layer.cpp
source/scwx/qt/map/radar_range_layer.cpp
source/scwx/qt/map/radar_site_layer.cpp)
Expand All @@ -154,6 +158,7 @@ set(HDR_MODEL source/scwx/qt/model/alert_model.hpp
source/scwx/qt/model/imgui_context_model.hpp
source/scwx/qt/model/layer_model.hpp
source/scwx/qt/model/placefile_model.hpp
source/scwx/qt/model/marker_model.hpp
source/scwx/qt/model/radar_site_model.hpp
source/scwx/qt/model/tree_item.hpp
source/scwx/qt/model/tree_model.hpp)
Expand All @@ -162,6 +167,7 @@ set(SRC_MODEL source/scwx/qt/model/alert_model.cpp
source/scwx/qt/model/imgui_context_model.cpp
source/scwx/qt/model/layer_model.cpp
source/scwx/qt/model/placefile_model.cpp
source/scwx/qt/model/marker_model.cpp
source/scwx/qt/model/radar_site_model.cpp
source/scwx/qt/model/tree_item.cpp
source/scwx/qt/model/tree_model.cpp)
Expand Down Expand Up @@ -215,6 +221,7 @@ set(HDR_TYPES source/scwx/qt/types/alert_types.hpp
source/scwx/qt/types/location_types.hpp
source/scwx/qt/types/map_types.hpp
source/scwx/qt/types/media_types.hpp
source/scwx/qt/types/marker_types.hpp
source/scwx/qt/types/qt_types.hpp
source/scwx/qt/types/radar_product_record.hpp
source/scwx/qt/types/text_event_key.hpp
Expand Down Expand Up @@ -260,6 +267,8 @@ set(HDR_UI source/scwx/qt/ui/about_dialog.hpp
source/scwx/qt/ui/open_url_dialog.hpp
source/scwx/qt/ui/placefile_dialog.hpp
source/scwx/qt/ui/placefile_settings_widget.hpp
source/scwx/qt/ui/marker_dialog.hpp
source/scwx/qt/ui/marker_settings_widget.hpp
source/scwx/qt/ui/progress_dialog.hpp
source/scwx/qt/ui/radar_site_dialog.hpp
source/scwx/qt/ui/serial_port_dialog.hpp
Expand Down Expand Up @@ -288,6 +297,8 @@ set(SRC_UI source/scwx/qt/ui/about_dialog.cpp
source/scwx/qt/ui/open_url_dialog.cpp
source/scwx/qt/ui/placefile_dialog.cpp
source/scwx/qt/ui/placefile_settings_widget.cpp
source/scwx/qt/ui/marker_dialog.cpp
source/scwx/qt/ui/marker_settings_widget.cpp
source/scwx/qt/ui/progress_dialog.cpp
source/scwx/qt/ui/radar_site_dialog.cpp
source/scwx/qt/ui/settings_dialog.cpp
Expand All @@ -307,6 +318,8 @@ set(UI_UI source/scwx/qt/ui/about_dialog.ui
source/scwx/qt/ui/open_url_dialog.ui
source/scwx/qt/ui/placefile_dialog.ui
source/scwx/qt/ui/placefile_settings_widget.ui
source/scwx/qt/ui/marker_dialog.ui
source/scwx/qt/ui/marker_settings_widget.ui
source/scwx/qt/ui/progress_dialog.ui
source/scwx/qt/ui/radar_site_dialog.ui
source/scwx/qt/ui/settings_dialog.ui
Expand Down
1 change: 1 addition & 0 deletions scwx-qt/scwx-qt.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@
<file>res/textures/images/cursor-17.png</file>
<file>res/textures/images/crosshairs-24.png</file>
<file>res/textures/images/dot-3.png</file>
<file>res/textures/images/location-marker.svg</file>
<file>res/textures/images/mapbox-logo.svg</file>
<file>res/textures/images/maptiler-logo.svg</file>
</qresource>
Expand Down
14 changes: 14 additions & 0 deletions scwx-qt/source/scwx/qt/main/main_window.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include <scwx/qt/manager/alert_manager.hpp>
#include <scwx/qt/manager/hotkey_manager.hpp>
#include <scwx/qt/manager/placefile_manager.hpp>
#include <scwx/qt/manager/marker_manager.hpp>
#include <scwx/qt/manager/position_manager.hpp>
#include <scwx/qt/manager/radar_product_manager.hpp>
#include <scwx/qt/manager/text_event_manager.hpp>
Expand All @@ -30,6 +31,7 @@
#include <scwx/qt/ui/level2_settings_widget.hpp>
#include <scwx/qt/ui/level3_products_widget.hpp>
#include <scwx/qt/ui/placefile_dialog.hpp>
#include <scwx/qt/ui/marker_dialog.hpp>
#include <scwx/qt/ui/radar_site_dialog.hpp>
#include <scwx/qt/ui/settings_dialog.hpp>
#include <scwx/qt/ui/update_dialog.hpp>
Expand Down Expand Up @@ -86,11 +88,13 @@ class MainWindowImpl : public QObject
imGuiDebugDialog_ {nullptr},
layerDialog_ {nullptr},
placefileDialog_ {nullptr},
markerDialog_ {nullptr},
radarSiteDialog_ {nullptr},
settingsDialog_ {nullptr},
updateDialog_ {nullptr},
alertManager_ {manager::AlertManager::Instance()},
placefileManager_ {manager::PlacefileManager::Instance()},
markerManager_ {manager::MarkerManager::Instance()},
positionManager_ {manager::PositionManager::Instance()},
textEventManager_ {manager::TextEventManager::Instance()},
timelineManager_ {manager::TimelineManager::Instance()},
Expand Down Expand Up @@ -203,6 +207,7 @@ class MainWindowImpl : public QObject
ui::ImGuiDebugDialog* imGuiDebugDialog_;
ui::LayerDialog* layerDialog_;
ui::PlacefileDialog* placefileDialog_;
ui::MarkerDialog* markerDialog_;
ui::RadarSiteDialog* radarSiteDialog_;
ui::SettingsDialog* settingsDialog_;
ui::UpdateDialog* updateDialog_;
Expand All @@ -217,6 +222,7 @@ class MainWindowImpl : public QObject
std::shared_ptr<manager::HotkeyManager> hotkeyManager_ {
manager::HotkeyManager::Instance()};
std::shared_ptr<manager::PlacefileManager> placefileManager_;
std::shared_ptr<manager::MarkerManager> markerManager_;
std::shared_ptr<manager::PositionManager> positionManager_;
std::shared_ptr<manager::TextEventManager> textEventManager_;
std::shared_ptr<manager::TimelineManager> timelineManager_;
Expand Down Expand Up @@ -303,6 +309,9 @@ MainWindow::MainWindow(QWidget* parent) :
// Placefile Manager Dialog
p->placefileDialog_ = new ui::PlacefileDialog(this);

// Marker Manager Dialog
p->markerDialog_ = new ui::MarkerDialog(this);

// Layer Dialog
p->layerDialog_ = new ui::LayerDialog(this);

Expand Down Expand Up @@ -610,6 +619,11 @@ void MainWindow::on_actionPlacefileManager_triggered()
p->placefileDialog_->show();
}

void MainWindow::on_actionMarkerManager_triggered()
{
p->markerDialog_->show();
}

void MainWindow::on_actionLayerManager_triggered()
{
p->layerDialog_->show();
Expand Down
1 change: 1 addition & 0 deletions scwx-qt/source/scwx/qt/main/main_window.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ private slots:
void on_actionRadarRange_triggered(bool checked);
void on_actionRadarSites_triggered(bool checked);
void on_actionPlacefileManager_triggered();
void on_actionMarkerManager_triggered();
void on_actionLayerManager_triggered();
void on_actionImGuiDebug_triggered();
void on_actionDumpLayerList_triggered();
Expand Down
16 changes: 13 additions & 3 deletions scwx-qt/source/scwx/qt/main/main_window.ui
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
<x>0</x>
<y>0</y>
<width>1024</width>
<height>33</height>
<height>22</height>
</rect>
</property>
<widget class="QMenu" name="menuFile">
Expand Down Expand Up @@ -104,6 +104,7 @@
</property>
<addaction name="actionPlacefileManager"/>
<addaction name="actionLayerManager"/>
<addaction name="actionMarkerManager"/>
</widget>
<addaction name="menuFile"/>
<addaction name="menuView"/>
Expand Down Expand Up @@ -152,8 +153,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>190</width>
<height>686</height>
<width>205</width>
<height>701</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_6">
Expand Down Expand Up @@ -487,6 +488,15 @@
<string>&amp;GPS Info</string>
</property>
</action>
<action name="actionMarkerManager">
<property name="icon">
<iconset resource="../../../../scwx-qt.qrc">
<normaloff>:/res/icons/font-awesome-6/house-solid.svg</normaloff>:/res/icons/font-awesome-6/house-solid.svg</iconset>
</property>
<property name="text">
<string>Location &amp;Marker Manager</string>
</property>
</action>
</widget>
<resources>
<include location="../../../../scwx-qt.qrc"/>
Expand Down
Loading

0 comments on commit 1843f38

Please sign in to comment.