Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
22206512
Commit
22206512
authored
Apr 24, 2014
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
TagBuilder: add method AddEmptyItem()
parent
7fdd8014
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
0 deletions
+17
-0
TagBuilder.cxx
src/tag/TagBuilder.cxx
+10
-0
TagBuilder.hxx
src/tag/TagBuilder.hxx
+7
-0
No files found.
src/tag/TagBuilder.cxx
View file @
22206512
...
...
@@ -219,6 +219,16 @@ TagBuilder::AddItem(TagType type, const char *value)
}
void
TagBuilder
::
AddEmptyItem
(
TagType
type
)
{
tag_pool_lock
.
lock
();
auto
i
=
tag_pool_get_item
(
type
,
""
,
0
);
tag_pool_lock
.
unlock
();
items
.
push_back
(
i
);
}
void
TagBuilder
::
RemoveAll
()
{
tag_pool_lock
.
lock
();
...
...
src/tag/TagBuilder.hxx
View file @
22206512
...
...
@@ -154,6 +154,13 @@ public:
void
AddItem
(
TagType
type
,
const
char
*
value
);
/**
* Appends a new tag item with an empty value. Do not use
* this unless you know what you're doing - because usually,
* empty values are discarded.
*/
void
AddEmptyItem
(
TagType
type
);
/**
* Removes all tag items.
*/
void
RemoveAll
();
...
...
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