Commit bc452aa6 authored by Pierre Kraemer's avatar Pierre Kraemer

SCHNApps: v1 !!!

parent f0cd17c2
...@@ -25,27 +25,25 @@ file( ...@@ -25,27 +25,25 @@ file(
${SCHNApps_ROOT_DIR}/src/main.cpp ${SCHNApps_ROOT_DIR}/src/main.cpp
${SCHNApps_ROOT_DIR}/src/mapHandler.cpp ${SCHNApps_ROOT_DIR}/src/mapHandler.cpp
${SCHNApps_ROOT_DIR}/src/plugin.cpp ${SCHNApps_ROOT_DIR}/src/plugin.cpp
${SCHNApps_ROOT_DIR}/src/splitArea.cpp
${SCHNApps_ROOT_DIR}/src/system.cpp ${SCHNApps_ROOT_DIR}/src/system.cpp
${SCHNApps_ROOT_DIR}/src/view.cpp ${SCHNApps_ROOT_DIR}/src/view.cpp
${SCHNApps_ROOT_DIR}/src/window.cpp ${SCHNApps_ROOT_DIR}/src/window.cpp
${SCHNApps_ROOT_DIR}/src/viewButtonArea.cpp ${SCHNApps_ROOT_DIR}/src/viewButtonArea.cpp
${SCHNApps_ROOT_DIR}/src/viewSelector.cpp ${SCHNApps_ROOT_DIR}/src/camerasDialog.cpp
${SCHNApps_ROOT_DIR}/src/cameraDialog.cpp ${SCHNApps_ROOT_DIR}/src/pluginsDialog.cpp
${SCHNApps_ROOT_DIR}/src/pluginDialog.cpp ${SCHNApps_ROOT_DIR}/src/mapsDialog.cpp
${SCHNApps_ROOT_DIR}/src/cameraViewDialog.cpp ${SCHNApps_ROOT_DIR}/src/cameraViewDialog.cpp
${SCHNApps_ROOT_DIR}/src/pluginsViewDialog.cpp ${SCHNApps_ROOT_DIR}/src/pluginsViewDialog.cpp
${SCHNApps_ROOT_DIR}/src/mapsViewDialog.cpp ${SCHNApps_ROOT_DIR}/src/mapsViewDialog.cpp
) )
SET(SCHNApps_H_OBJECT_FILES SET(SCHNApps_H_OBJECT_FILES
${SCHNApps_ROOT_DIR}/include/splitArea.h
${SCHNApps_ROOT_DIR}/include/view.h ${SCHNApps_ROOT_DIR}/include/view.h
${SCHNApps_ROOT_DIR}/include/window.h ${SCHNApps_ROOT_DIR}/include/window.h
${SCHNApps_ROOT_DIR}/include/viewButtonArea.h ${SCHNApps_ROOT_DIR}/include/viewButtonArea.h
${SCHNApps_ROOT_DIR}/include/viewSelector.h ${SCHNApps_ROOT_DIR}/include/camerasDialog.h
${SCHNApps_ROOT_DIR}/include/cameraDialog.h ${SCHNApps_ROOT_DIR}/include/pluginsDialog.h
${SCHNApps_ROOT_DIR}/include/pluginDialog.h ${SCHNApps_ROOT_DIR}/include/mapsDialog.h
${SCHNApps_ROOT_DIR}/include/cameraViewDialog.h ${SCHNApps_ROOT_DIR}/include/cameraViewDialog.h
${SCHNApps_ROOT_DIR}/include/pluginsViewDialog.h ${SCHNApps_ROOT_DIR}/include/pluginsViewDialog.h
${SCHNApps_ROOT_DIR}/include/mapsViewDialog.h ${SCHNApps_ROOT_DIR}/include/mapsViewDialog.h
...@@ -55,8 +53,9 @@ file( ...@@ -55,8 +53,9 @@ file(
GLOB GLOB
SCHNApps_FORM_FILES SCHNApps_FORM_FILES
${SCHNApps_ROOT_DIR}/forms/window.ui ${SCHNApps_ROOT_DIR}/forms/window.ui
${SCHNApps_ROOT_DIR}/forms/cameraDialog.ui ${SCHNApps_ROOT_DIR}/forms/camerasDialog.ui
${SCHNApps_ROOT_DIR}/forms/pluginDialog.ui ${SCHNApps_ROOT_DIR}/forms/pluginsDialog.ui
${SCHNApps_ROOT_DIR}/forms/mapsDialog.ui
${SCHNApps_ROOT_DIR}/forms/cameraViewDialog.ui ${SCHNApps_ROOT_DIR}/forms/cameraViewDialog.ui
${SCHNApps_ROOT_DIR}/forms/pluginsViewDialog.ui ${SCHNApps_ROOT_DIR}/forms/pluginsViewDialog.ui
${SCHNApps_ROOT_DIR}/forms/mapsViewDialog.ui ${SCHNApps_ROOT_DIR}/forms/mapsViewDialog.ui
......
...@@ -25,27 +25,25 @@ file( ...@@ -25,27 +25,25 @@ file(
${SCHNApps_ROOT_DIR}/src/main.cpp ${SCHNApps_ROOT_DIR}/src/main.cpp
${SCHNApps_ROOT_DIR}/src/mapHandler.cpp ${SCHNApps_ROOT_DIR}/src/mapHandler.cpp
${SCHNApps_ROOT_DIR}/src/plugin.cpp ${SCHNApps_ROOT_DIR}/src/plugin.cpp
${SCHNApps_ROOT_DIR}/src/splitArea.cpp
${SCHNApps_ROOT_DIR}/src/system.cpp ${SCHNApps_ROOT_DIR}/src/system.cpp
${SCHNApps_ROOT_DIR}/src/view.cpp ${SCHNApps_ROOT_DIR}/src/view.cpp
${SCHNApps_ROOT_DIR}/src/window.cpp ${SCHNApps_ROOT_DIR}/src/window.cpp
${SCHNApps_ROOT_DIR}/src/viewButtonArea.cpp ${SCHNApps_ROOT_DIR}/src/viewButtonArea.cpp
${SCHNApps_ROOT_DIR}/src/viewSelector.cpp ${SCHNApps_ROOT_DIR}/src/camerasDialog.cpp
${SCHNApps_ROOT_DIR}/src/cameraDialog.cpp ${SCHNApps_ROOT_DIR}/src/pluginsDialog.cpp
${SCHNApps_ROOT_DIR}/src/pluginDialog.cpp ${SCHNApps_ROOT_DIR}/src/mapsDialog.cpp
${SCHNApps_ROOT_DIR}/src/cameraViewDialog.cpp ${SCHNApps_ROOT_DIR}/src/cameraViewDialog.cpp
${SCHNApps_ROOT_DIR}/src/pluginsViewDialog.cpp ${SCHNApps_ROOT_DIR}/src/pluginsViewDialog.cpp
${SCHNApps_ROOT_DIR}/src/mapsViewDialog.cpp ${SCHNApps_ROOT_DIR}/src/mapsViewDialog.cpp
) )
SET(SCHNApps_H_OBJECT_FILES SET(SCHNApps_H_OBJECT_FILES
${SCHNApps_ROOT_DIR}/include/splitArea.h
${SCHNApps_ROOT_DIR}/include/view.h ${SCHNApps_ROOT_DIR}/include/view.h
${SCHNApps_ROOT_DIR}/include/window.h ${SCHNApps_ROOT_DIR}/include/window.h
${SCHNApps_ROOT_DIR}/include/viewButtonArea.h ${SCHNApps_ROOT_DIR}/include/viewButtonArea.h
${SCHNApps_ROOT_DIR}/include/viewSelector.h ${SCHNApps_ROOT_DIR}/include/camerasDialog.h
${SCHNApps_ROOT_DIR}/include/cameraDialog.h ${SCHNApps_ROOT_DIR}/include/pluginsDialog.h
${SCHNApps_ROOT_DIR}/include/pluginDialog.h ${SCHNApps_ROOT_DIR}/include/mapsDialog.h
${SCHNApps_ROOT_DIR}/include/cameraViewDialog.h ${SCHNApps_ROOT_DIR}/include/cameraViewDialog.h
${SCHNApps_ROOT_DIR}/include/pluginsViewDialog.h ${SCHNApps_ROOT_DIR}/include/pluginsViewDialog.h
${SCHNApps_ROOT_DIR}/include/mapsViewDialog.h ${SCHNApps_ROOT_DIR}/include/mapsViewDialog.h
...@@ -55,8 +53,9 @@ file( ...@@ -55,8 +53,9 @@ file(
GLOB GLOB
SCHNApps_FORM_FILES SCHNApps_FORM_FILES
${SCHNApps_ROOT_DIR}/forms/window.ui ${SCHNApps_ROOT_DIR}/forms/window.ui
${SCHNApps_ROOT_DIR}/forms/cameraDialog.ui ${SCHNApps_ROOT_DIR}/forms/camerasDialog.ui
${SCHNApps_ROOT_DIR}/forms/pluginDialog.ui ${SCHNApps_ROOT_DIR}/forms/pluginsDialog.ui
${SCHNApps_ROOT_DIR}/forms/mapsDialog.ui
${SCHNApps_ROOT_DIR}/forms/cameraViewDialog.ui ${SCHNApps_ROOT_DIR}/forms/cameraViewDialog.ui
${SCHNApps_ROOT_DIR}/forms/pluginsViewDialog.ui ${SCHNApps_ROOT_DIR}/forms/pluginsViewDialog.ui
${SCHNApps_ROOT_DIR}/forms/mapsViewDialog.ui ${SCHNApps_ROOT_DIR}/forms/mapsViewDialog.ui
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0"> <ui version="4.0">
<class>CameraDialog</class> <class>CamerasDialog</class>
<widget class="QDialog" name="CameraDialog"> <widget class="QDialog" name="CamerasDialog">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>0</x> <x>0</x>
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string>CameraDialog</string> <string>CamerasDialog</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_2"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QPushButton" name="removeCameraButton"> <widget class="QPushButton" name="removeCamerasButton">
<property name="text"> <property name="text">
<string>Remove</string> <string>Remove</string>
</property> </property>
...@@ -35,7 +35,11 @@ ...@@ -35,7 +35,11 @@
</layout> </layout>
</item> </item>
<item> <item>
<widget class="QListWidget" name="cameraList"/> <widget class="QListWidget" name="cameraList">
<property name="selectionMode">
<enum>QAbstractItemView::ExtendedSelection</enum>
</property>
</widget>
</item> </item>
</layout> </layout>
</item> </item>
...@@ -53,7 +57,7 @@ ...@@ -53,7 +57,7 @@
<connection> <connection>
<sender>OKButton</sender> <sender>OKButton</sender>
<signal>clicked()</signal> <signal>clicked()</signal>
<receiver>CameraDialog</receiver> <receiver>CamerasDialog</receiver>
<slot>accept()</slot> <slot>accept()</slot>
<hints> <hints>
<hint type="sourcelabel"> <hint type="sourcelabel">
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0"> <ui version="4.0">
<class>PluginDialog</class> <class>PluginsDialog</class>
<widget class="QDialog" name="PluginDialog"> <widget class="QDialog" name="PluginsDialog">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>0</x> <x>0</x>
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string>PluginDialog</string> <string>PluginsDialog</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
...@@ -97,7 +97,7 @@ ...@@ -97,7 +97,7 @@
<connection> <connection>
<sender>OKButton</sender> <sender>OKButton</sender>
<signal>pressed()</signal> <signal>pressed()</signal>
<receiver>PluginDialog</receiver> <receiver>PluginsDialog</receiver>
<slot>accept()</slot> <slot>accept()</slot>
<hints> <hints>
<hint type="sourcelabel"> <hint type="sourcelabel">
...@@ -111,9 +111,9 @@ ...@@ -111,9 +111,9 @@
</hints> </hints>
</connection> </connection>
<connection> <connection>
<sender>PluginDialog</sender> <sender>PluginsDialog</sender>
<signal>rejected()</signal> <signal>rejected()</signal>
<receiver>PluginDialog</receiver> <receiver>PluginsDialog</receiver>
<slot>accept()</slot> <slot>accept()</slot>
<hints> <hints>
<hint type="sourcelabel"> <hint type="sourcelabel">
......
...@@ -6,8 +6,8 @@ ...@@ -6,8 +6,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>785</width> <width>800</width>
<height>593</height> <height>600</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
...@@ -23,8 +23,8 @@ ...@@ -23,8 +23,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>785</width> <width>800</width>
<height>22</height> <height>23</height>
</rect> </rect>
</property> </property>
<widget class="QMenu" name="menuFile"> <widget class="QMenu" name="menuFile">
...@@ -78,7 +78,7 @@ ...@@ -78,7 +78,7 @@
<action name="actionManagePlugins"> <action name="actionManagePlugins">
<property name="icon"> <property name="icon">
<iconset resource="../resources/resources.qrc"> <iconset resource="../resources/resources.qrc">
<normaloff>:/icons/icons/action_plugins.png</normaloff>:/icons/icons/action_plugins.png</iconset> <normaloff>:/icons/icons/plugins.png</normaloff>:/icons/icons/plugins.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>Manage plugins</string> <string>Manage plugins</string>
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
<action name="actionManageCameras"> <action name="actionManageCameras">
<property name="icon"> <property name="icon">
<iconset resource="../resources/resources.qrc"> <iconset resource="../resources/resources.qrc">
<normaloff>:/icons/icons/action_cameras.png</normaloff>:/icons/icons/action_cameras.png</iconset> <normaloff>:/icons/icons/cameras.png</normaloff>:/icons/icons/cameras.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>Manage cameras</string> <string>Manage cameras</string>
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
<action name="actionManageMaps"> <action name="actionManageMaps">
<property name="icon"> <property name="icon">
<iconset resource="../resources/resources.qrc"> <iconset resource="../resources/resources.qrc">
<normaloff>:/icons/icons/action_maps.png</normaloff>:/icons/icons/action_maps.png</iconset> <normaloff>:/icons/icons/maps.png</normaloff>:/icons/icons/maps.png</iconset>
</property> </property>
<property name="text"> <property name="text">
<string>ManageMaps</string> <string>ManageMaps</string>
......
...@@ -20,7 +20,7 @@ public: ...@@ -20,7 +20,7 @@ public:
Window* getWindow() const { return m_window; } Window* getWindow() const { return m_window; }
void setWindow(Window* w) { m_window = w; } void setWindow(Window* w) { m_window = w; }
bool isUsed() const { return l_views.size() > 0; } bool isUsed() const { return !l_views.empty(); }
bool isShared() const { return l_views.size() > 1; } bool isShared() const { return l_views.size() > 1; }
/********************************************************* /*********************************************************
......
#ifndef _CAMERADIALOG_H_ #ifndef _CAMERASDIALOG_H_
#define _CAMERADIALOG_H_ #define _CAMERASDIALOG_H_
#include "ui_cameraDialog.h" #include "ui_camerasDialog.h"
class Window; class Window;
class Camera; class Camera;
class CameraDialog : public QDialog, Ui::CameraDialog class CamerasDialog : public QDialog, Ui::CamerasDialog
{ {
Q_OBJECT Q_OBJECT
public: public:
CameraDialog(Window* window); CamerasDialog(Window* window);
~CameraDialog(); ~CamerasDialog();
private: private:
Window* m_window; Window* m_window;
public slots: public slots:
void cb_addCamera(); void cb_addCamera();
void cb_removeCamera(); void cb_removeCameras();
void cb_addCameraToList(Camera* c); void cb_addCameraToList(Camera* c);
void cb_removeCameraFromList(Camera* c); void cb_removeCameraFromList(Camera* c);
}; };
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
#include "types.h" #include "types.h"
#include "view.h" #include "view.h"
#include "Topology/generic/genericmap.h"
#include "Topology/generic/functor.h" #include "Topology/generic/functor.h"
#include "Utils/vbo.h" #include "Utils/vbo.h"
#include "Algo/Render/GL2/mapRender.h" #include "Algo/Render/GL2/mapRender.h"
...@@ -13,7 +14,7 @@ ...@@ -13,7 +14,7 @@
class MapHandlerGen class MapHandlerGen
{ {
public: public:
MapHandlerGen(const QString& name, Window* window); MapHandlerGen(const QString& name, Window* window, CGoGN::GenericMap* map);
virtual ~MapHandlerGen(); virtual ~MapHandlerGen();
const QString& getName() const { return m_name; } const QString& getName() const { return m_name; }
...@@ -22,6 +23,8 @@ public: ...@@ -22,6 +23,8 @@ public:
Window* getWindow() const { return m_window; } Window* getWindow() const { return m_window; }
void setWindow(Window* w) { m_window = w; } void setWindow(Window* w) { m_window = w; }
CGoGN::GenericMap* getGenericMap() { return m_map; }
const qglviewer::Vec& getBBmin() const { return m_bbMin; } const qglviewer::Vec& getBBmin() const { return m_bbMin; }
void setBBmin(qglviewer::Vec& v) { m_bbMin = v; } void setBBmin(qglviewer::Vec& v) { m_bbMin = v; }
...@@ -30,6 +33,8 @@ public: ...@@ -30,6 +33,8 @@ public:
float getBBdiagSize() { return (m_bbMax - m_bbMin).norm(); } float getBBdiagSize() { return (m_bbMax - m_bbMin).norm(); }
bool isUsed() const { return !l_views.empty(); }
void draw(CGoGN::Utils::GLSLShader* shader, int primitive); void draw(CGoGN::Utils::GLSLShader* shader, int primitive);
/********************************************************* /*********************************************************
...@@ -43,7 +48,7 @@ public: ...@@ -43,7 +48,7 @@ public:
* MANAGE LINKED VIEWS * MANAGE LINKED VIEWS
*********************************************************/ *********************************************************/
bool linkView(View* view); void linkView(View* view);
void unlinkView(View* view); void unlinkView(View* view);
const QList<View*>& getLinkedViews() const { return l_views; } const QList<View*>& getLinkedViews() const { return l_views; }
bool isLinkedToView(View* view) const { return l_views.contains(view); } bool isLinkedToView(View* view) const { return l_views.contains(view); }
...@@ -51,6 +56,7 @@ public: ...@@ -51,6 +56,7 @@ public:
protected: protected:
QString m_name; QString m_name;
Window* m_window; Window* m_window;
CGoGN::GenericMap* m_map;
CGoGN::Algo::Render::GL2::MapRender* m_render; CGoGN::Algo::Render::GL2::MapRender* m_render;
...@@ -67,8 +73,7 @@ class MapHandler : public MapHandlerGen ...@@ -67,8 +73,7 @@ class MapHandler : public MapHandlerGen
{ {
public: public:
MapHandler(const QString& name, Window* window, typename PFP::MAP* map) : MapHandler(const QString& name, Window* window, typename PFP::MAP* map) :
MapHandlerGen(name, window), MapHandlerGen(name, window, map)
m_map(map)
{} {}
~MapHandler() ~MapHandler()
...@@ -77,15 +82,12 @@ public: ...@@ -77,15 +82,12 @@ public:
delete m_map; delete m_map;
} }
typename PFP::MAP* getMap() { return m_map; } typename PFP::MAP* getMap() { return reinterpret_cast<typename PFP::MAP*>(m_map); }
void updatePrimitives(int primitive, const CGoGN::FunctorSelect& good) void updatePrimitives(int primitive, const CGoGN::FunctorSelect& good)
{ {
m_render->initPrimitives<PFP>(*m_map, good, primitive) ; m_render->initPrimitives<PFP>(*(reinterpret_cast<typename PFP::MAP*>(m_map)), good, primitive) ;
} }
protected:
typename PFP::MAP* m_map;
}; };
#endif #endif
...@@ -28,6 +28,8 @@ public: ...@@ -28,6 +28,8 @@ public:
Window* getWindow() { return m_window; } Window* getWindow() { return m_window; }
void setWindow(Window* w) { m_window = w; } void setWindow(Window* w) { m_window = w; }
bool isUsed() const { return !l_views.empty(); }
bool getProvidesRendering() { return b_providesRendering; } bool getProvidesRendering() { return b_providesRendering; }
void setProvidesRendering(bool b) { b_providesRendering = b; } void setProvidesRendering(bool b) { b_providesRendering = b; }
......
#ifndef _PLUGINDIALOG_H_ #ifndef _PLUGINSDIALOG_H_
#define _PLUGINDIALOG_H_ #define _PLUGINSDIALOG_H_
#include "ui_pluginDialog.h" #include "ui_pluginsDialog.h"
#include "types.h" #include "types.h"
...@@ -18,13 +18,13 @@ struct PluginInfo ...@@ -18,13 +18,13 @@ struct PluginInfo
QString pluginName; QString pluginName;
}; };
class PluginDialog : public QDialog, public Ui::PluginDialog class PluginsDialog : public QDialog, public Ui::PluginsDialog
{ {
Q_OBJECT Q_OBJECT
public: public:
PluginDialog(Window* window); PluginsDialog(Window* window);
~PluginDialog(); ~PluginsDialog();
protected: protected:
Window* m_window; Window* m_window;
......
#ifndef _SPLITAREA_H_
#define _SPLITAREA_H_
#include <QSplitter>
class SplitArea : public QSplitter
{
Q_OBJECT
public:
SplitArea(QWidget* parent = NULL);
int getNbRows() { return nbRows; }
void addFitElement(QWidget* element);
void addElementAt(QWidget* element, int x, int y);
void addElementRightTo(QWidget* element, QWidget* left);
bool isEmpty();
void updateSize();
protected:
int nbRows;
int maxNbColumns;
int rowMin;
int nbElements;
protected slots:
void elementRemoved();
private:
bool sizeUpdated;
void determineRowMin();
};
#endif
...@@ -22,7 +22,7 @@ class View : public QGLViewer ...@@ -22,7 +22,7 @@ class View : public QGLViewer
public: public:
static unsigned int viewCount; static unsigned int viewCount;
View(const QString& name, Window* w, QWidget* parent, const QGLWidget* shareWidget = NULL); View(const QString& name, Window* w, const QGLWidget* shareWidget = NULL);
~View(); ~View();
const QString& getName() const { return m_name; } const QString& getName() const { return m_name; }
...@@ -104,6 +104,8 @@ protected: ...@@ -104,6 +104,8 @@ protected:
ViewButton* m_pluginsButton; ViewButton* m_pluginsButton;
ViewButton* m_mapsButton; ViewButton* m_mapsButton;
ViewButton* m_closeButton; ViewButton* m_closeButton;
ViewButton* m_VsplitButton;
ViewButton* m_HsplitButton;
QString m_textInfo; QString m_textInfo;
...@@ -116,6 +118,8 @@ public slots: ...@@ -116,6 +118,8 @@ public slots:
void cb_pluginsView(int x, int y, int globalX, int globalY); void cb_pluginsView(int x, int y, int globalX, int globalY);
void cb_mapsView(int x, int y, int globalX, int globalY); void cb_mapsView(int x, int y, int globalX, int globalY);
void cb_closeView(int x, int y, int globalX, int globalY); void cb_closeView(int x, int y, int globalX, int globalY);
void cb_VsplitView(int x, int y, int globalX, int globalY);
void cb_HsplitView(int x, int y, int globalX, int globalY);
}; };
#endif #endif
...@@ -25,6 +25,9 @@ public: ...@@ -25,6 +25,9 @@ public:
void click(int x, int y, int globalX, int globalY); void click(int x, int y, int globalX, int globalY);
void drawAt(int x, int y); void drawAt(int x, int y);
static const int SIZE = 24;
static const int SPACE = 4;
protected: protected:
QString m_img; QString m_img;
View* m_view; View* m_view;
...@@ -39,7 +42,9 @@ class ViewButtonArea : public QObject ...@@ -39,7 +42,9 @@ class ViewButtonArea : public QObject
Q_OBJECT Q_OBJECT
public: public:
ViewButtonArea(View* view) : m_view(view) ViewButtonArea(View* view) :
m_view(view),
m_form(0,0,0,0)
{} {}
~ViewButtonArea() ~ViewButtonArea()
{} {}
......
#ifndef _VIEWSELECTOR_H_
#define _VIEWSELECTOR_H_
#include "view.h"
#include <QDialog>
#include <QRect>
class SplitArea;
class PixElem
{
public: