[ios] Autocreate not existing bookmark category when displaying bookmark sets to users

This commit is contained in:
Alex Zolotarev 2012-10-14 03:21:15 +03:00 committed by Alex Zolotarev
parent ee90a76e4b
commit 7dcb8cc696
2 changed files with 4 additions and 1 deletions

View file

@ -11,6 +11,9 @@
if (self)
{
m_balloon = view;
// Always autocreate bookmark category if it's absent
GetFramework().GetBmCategory([m_balloon.setName UTF8String]);
self.title = NSLocalizedString(@"bookmark_sets", @"Bookmark Sets dialog title");
}

View file

@ -388,7 +388,7 @@ BookmarkCategory * Framework::GetBmCategory(size_t index) const
BookmarkCategory * Framework::GetBmCategory(string const & name)
{
vector<BookmarkCategory *>::iterator i = FindBmCategory(name);
CategoryIter i = FindBmCategory(name);
if (i != m_bookmarks.end())
return (*i);