Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
bd86b721
Commit
bd86b721
authored
Dec 06, 2018
by
Christoffer Ackelman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
QT: Simplified ge_subpalette.
parent
78c8cba3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
13 deletions
+17
-13
xtt/lib/ge/qt/ge_qt.cqt
xtt/lib/ge/qt/ge_qt.cqt
+1
-0
xtt/lib/ge/qt/ge_subpalette_qt.cqt
xtt/lib/ge/qt/ge_subpalette_qt.cqt
+8
-8
xtt/lib/ge/qt/ge_subpalette_qt.h
xtt/lib/ge/qt/ge_subpalette_qt.h
+8
-5
No files found.
xtt/lib/ge/qt/ge_qt.cqt
View file @
bd86b721
...
...
@@ -1265,6 +1265,7 @@ GeQt::~GeQt()
if (subgraphs) {
delete subgraphs;
}
delete subpalette;
delete recall_entry;
delete text_recall;
delete name_recall;
...
...
xtt/lib/ge/qt/ge_subpalette_qt.cqt
View file @
bd86b721
...
...
@@ -47,24 +47,24 @@
SubPaletteQt::SubPaletteQt(void* xn_parent_ctx, QWidget* xn_parent_wid,
const char* xn_name, QWidget** w, pwr_tStatus* status)
: SubPalette(xn_parent_ctx, xn_name, status)
: SubPalette(xn_parent_ctx, xn_name, status)
, parent_widget(xn_parent_wid)
{
debug_print("creating a scrolledbrowwidgetqt\n");
object = new SubPaletteQtObject(this);
form_widget
= scrolledbrowwidgetqt_new(SubPalette::init_brow_cb, this, &brow_widget);
// Create the root item
*w = form_widget;
toplevel = new SubPaletteQtWidget(this, xn_parent_wid);
*status = 1;
}
SubPaletteQt::~SubPaletteQt()
{
de
bug_print("SubPaletteQt::~SubPaletteQt\n")
;
de
lete object
;
delete brow;
form_widget->close();
}
void SubPaletteQt::set_inputfocus(int focus)
...
...
@@ -83,14 +83,14 @@ void SubPaletteQt::create_popup_menu(char* filename, int x, int y)
CoWowQt::PopupPosition(form_widget, x, y, &wind_x, &wind_y);
QMenu* menu = new QMenu(
toplevel
);
addMenuItem(
toplevel
, menu, "Help", SLOT(activate_help()));
QMenu* menu = new QMenu(
parent_widget
);
addMenuItem(
object
, menu, "Help", SLOT(activate_help()));
menu->popup(QPoint(wind_x, wind_y));
}
// Callback from the menu.
void SubPaletteQt
Widge
t::activate_help()
void SubPaletteQt
Objec
t::activate_help()
{
char helpfile[80] = "$pwr_exe/man_subgraph.dat";
char topic[200];
...
...
xtt/lib/ge/qt/ge_subpalette_qt.h
View file @
bd86b721
...
...
@@ -46,7 +46,7 @@
/*! \addtogroup Ge */
/*@{*/
class
SubPaletteQt
Widge
t
;
class
SubPaletteQt
Objec
t
;
class
SubPaletteQt
:
public
SubPalette
{
public:
...
...
@@ -54,21 +54,24 @@ public:
QWidget
**
w
,
pwr_tStatus
*
status
);
~
SubPaletteQt
();
SubPaletteQt
Widget
*
toplevel
;
SubPaletteQt
Object
*
object
;
QWidget
*
brow_widget
;
QWidget
*
form_widget
;
char
popup_help_filename
[
200
];
void
set_inputfocus
(
int
focus
);
void
create_popup_menu
(
char
*
filename
,
int
x
,
int
y
);
private:
QWidget
*
parent_widget
;
};
class
SubPaletteQt
Widget
:
public
QWidge
t
{
class
SubPaletteQt
Object
:
public
QObjec
t
{
Q_OBJECT
public:
SubPaletteQt
Widget
(
SubPaletteQt
*
parent_ctx
,
QWidget
*
parent
)
:
Q
Widget
(
parent
),
subpalette
(
parent_ctx
)
SubPaletteQt
Object
(
SubPaletteQt
*
parent_ctx
)
:
Q
Object
(
),
subpalette
(
parent_ctx
)
{
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment