Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
RobotAPI
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Container Registry
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software
ArmarX
RobotAPI
Commits
df2fd405
Commit
df2fd405
authored
1 year ago
by
Peter Albrecht
Browse files
Options
Downloads
Patches
Plain Diff
Use env var instead of data path
parent
ed98c0ba
No related branches found
No related tags found
1 merge request
!406
Refactor skill memory GUI
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
source/RobotAPI/libraries/skills_gui/gui_utils.cpp
+5
-9
5 additions, 9 deletions
source/RobotAPI/libraries/skills_gui/gui_utils.cpp
source/RobotAPI/libraries/skills_gui/gui_utils.h
+1
-1
1 addition, 1 deletion
source/RobotAPI/libraries/skills_gui/gui_utils.h
with
6 additions
and
10 deletions
source/RobotAPI/libraries/skills_gui/gui_utils.cpp
+
5
−
9
View file @
df2fd405
...
...
@@ -118,18 +118,14 @@ armarx::gui::getIcon(std::string name)
if
(
armarXGuiPath
.
empty
())
{
std
::
scoped_lock
l
(
m_armarXGuiPath
);
armarXGuiPath
=
"ArmarXGui"
;
ArmarXDataPath
::
getAbsolutePath
(
armarXGuiPath
,
armarXGuiPath
);
armarXGuiPath
=
"$ARMARX_WORKSPACE/armarx/ArmarXGui/source/ArmarXGui/libraries/ArmarXGuiBase/icons/"
;
ArmarXDataPath
::
ReplaceEnvVars
(
armarXGuiPath
);
}
std
::
cout
<<
armarXGuiPath
;
// now we can use the path!
// what in god's good name is "armarx/ArmarXGui/data/ArmarXGui"? And why does the util
// say ArmarXGui is in there???????
// anyways. workaround until I figure out what the hell happens here.
QPixmap
pix
(
QString
::
fromStdString
(
armarXGuiPath
+
"/../../source/ArmarXGui/libraries/ArmarXGuiBase/icons/"
+
name
));
// we don't check the QIcon for validity, since an invalid icon can be safely used in the gui
QPixmap
pix
(
QString
::
fromStdString
(
armarXGuiPath
+
name
));
return
QIcon
(
pix
);
}
This diff is collapsed.
Click to expand it.
source/RobotAPI/libraries/skills_gui/gui_utils.h
+
1
−
1
View file @
df2fd405
...
...
@@ -20,7 +20,7 @@ namespace armarx::gui
/**
* @brief Get an icon in ArmarXGuiBase.
* @param name The name of the icon.
* @return The icon.
* @return The icon.
Empty icon if not found.
*/
QIcon
getIcon
(
std
::
string
name
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment