Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
RogueReborn
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Mikhail Andrenkov
RogueReborn
Commits
7e9b28c5
Commit
7e9b28c5
authored
8 years ago
by
Ian Prins
Browse files
Options
Downloads
Patches
Plain Diff
add context setter
parent
a684abf3
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/include/item.h
+1
-0
1 addition, 0 deletions
src/include/item.h
src/item.cpp
+4
-0
4 additions, 0 deletions
src/item.cpp
with
5 additions
and
0 deletions
src/include/item.h
+
1
−
0
View file @
7e9b28c5
...
...
@@ -22,6 +22,7 @@ class Item : public Feature {
bool
operator
<
(
const
Item
&
)
const
;
Context
getContext
();
void
setContext
(
Context
);
std
::
string
getDisplayName
();
std
::
string
getName
();
int
getType
();
...
...
This diff is collapsed.
Click to expand it.
src/item.cpp
+
4
−
0
View file @
7e9b28c5
...
...
@@ -44,6 +44,10 @@ Item::Context Item::getContext() {
return
this
->
context
;
}
void
Item
::
setContext
(
Item
::
Context
newContext
)
{
this
->
context
=
newContext
;
}
std
::
string
Item
::
getDisplayName
()
{
if
(
Item
::
identified
[
this
->
className
].
find
(
this
->
type
)
==
Item
::
identified
[
this
->
className
].
end
())
{
return
this
->
pseudoName
;
...
...
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