mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-29 14:52:12 +01:00
Add form to the OsgEarthView widget
This commit is contained in:
parent
c8d5a61316
commit
86ac80e2f2
@ -24,9 +24,19 @@ SOURCES += osgearthviewgadgetfactory.cpp
|
||||
SOURCES += osgearthviewgadgetconfiguration.cpp
|
||||
SOURCES += osgearthviewgadgetoptionspage.cpp
|
||||
|
||||
FORMS += osgearthviewgadgetoptionspage.ui
|
||||
FORMS += osgearthviewgadgetoptionspage.ui \
|
||||
osgearthview.ui
|
||||
|
||||
OTHER_FILES += OsgEarthviewGadget.pluginspec
|
||||
RESOURCES += osgearthview.qrc
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
32
ground/openpilotgcs/src/plugins/osgearthview/osgearthview.ui
Normal file
32
ground/openpilotgcs/src/plugins/osgearthview/osgearthview.ui
Normal file
@ -0,0 +1,32 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>OsgEarthview</class>
|
||||
<widget class="QWidget" name="OsgEarthview">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>400</width>
|
||||
<height>300</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Form</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="OsgViewerWidget" name="widget" native="true"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<customwidgets>
|
||||
<customwidget>
|
||||
<class>OsgViewerWidget</class>
|
||||
<extends>QWidget</extends>
|
||||
<header>osgviewerwidget.h</header>
|
||||
<container>1</container>
|
||||
</customwidget>
|
||||
</customwidgets>
|
||||
<resources/>
|
||||
<connections/>
|
||||
</ui>
|
@ -87,6 +87,8 @@ using namespace osgEarth::Annotation;
|
||||
|
||||
#include <iostream>
|
||||
|
||||
#include "ui_osgearthview.h"
|
||||
|
||||
#include "utils/stylehelper.h"
|
||||
#include "utils/homelocationutil.h"
|
||||
#include "utils/worldmagmodel.h"
|
||||
@ -99,11 +101,15 @@ using namespace Utils;
|
||||
|
||||
OsgEarthviewWidget::OsgEarthviewWidget(QWidget *parent) : QWidget(parent)
|
||||
{
|
||||
viewWidget = new OsgViewerWidget(this);
|
||||
|
||||
m_widget = new Ui_OsgEarthview();
|
||||
m_widget->setupUi(this);
|
||||
|
||||
/*viewWidget = new OsgViewerWidget(this);
|
||||
viewWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||
|
||||
setLayout(new QVBoxLayout());
|
||||
layout()->addWidget(viewWidget);
|
||||
layout()->addWidget(viewWidget);*/
|
||||
}
|
||||
|
||||
OsgEarthviewWidget::~OsgEarthviewWidget()
|
||||
|
@ -81,6 +81,8 @@ using namespace osgEarth::Annotation;
|
||||
|
||||
#include <iostream>
|
||||
|
||||
class Ui_OsgEarthview;
|
||||
|
||||
class OsgEarthviewWidget : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
@ -96,5 +98,6 @@ protected: /* Protected methods */
|
||||
void resizeEvent(QResizeEvent *event);
|
||||
|
||||
OsgViewerWidget *viewWidget;
|
||||
Ui_OsgEarthview *m_widget;
|
||||
};
|
||||
#endif /* OSGEARTHVIEWWIDGET_H_ */
|
||||
|
Loading…
x
Reference in New Issue
Block a user