using namespace Tizen::Ui::Scenes;
using namespace Tizen::System;
-static const wchar_t* IDB_TAB_ICON_BOOKMARKS = L"I01_tab_icon_bookmarks.png";
-static const wchar_t* IDB_TAB_ICON_HISTORY = L"I01_tab_icon_history.png";
-static const wchar_t* IDB_ICON_BOOKMARK_ON_TEMP = L"I01_icon_bookmark_on_temp.png";
-static const wchar_t* IDB_ICON_BOOKMARK_OFF_TEMP = L"I01_icon_bookmark_off_temp.png";
+static const wchar_t* IDB_TAB_ICON_BOOKMARKS = L"I01_search_list_icon_favorite.png";
+static const wchar_t* IDB_TAB_ICON_HISTORY =L"I01_search_list_icon_history.png";
+static const wchar_t* IDB_ICON_BOOKMARK_ON_TEMP = L"00_icon_favorite_on_74x74.png";
+static const wchar_t* IDB_ICON_BOOKMARK_OFF_TEMP = L"00_icon_favorite_off_74x74.png";
const int HistoryListForm::IDA_TABBAR_ITEM_1 = 101;
}
else
{
-
if(pSceneManager->GoBackward(BackwardSceneTransition(SCENE_TRANSITION_ANIMATION_TYPE_RIGHT))!= E_SUCCESS)
{
AppLogDebug("BookmarkListForm::OnActionPerformed GoBackward failed");
return;
}
-
}
}
if(__pGroupData == null)
{
delete pItem;
+ delete pImage;
return null;
}
if (pItem == null)
{
+ delete pImage;
return null;
}
pGroupItemClass = dynamic_cast< GroupItemClass* >(__pGroupData->GetAt(groupIndex));
if (pGroupItemClass == null)
{
delete pItem;
+ delete pImage;
return null;
}
if (pGroupItemClass->GetHistoryData() == null)
{
delete pItem;
+ delete pImage;
return null;
}
pHistory = dynamic_cast< History* >(pGroupItemClass->GetHistoryData()->GetAt(itemIndex));
if (pHistory == null)
{
delete pItem;
+ delete pImage;
return null;
}
r = pItem->Construct(Dimension(itemWidth, 128 - 44 + __fontSize), LIST_ANNEX_STYLE_NORMAL);
if (IsFailed(r))
{
delete pItem;
+ delete pImage;
return null;
}
if (IsFailed(r))
{
delete pItem;
+ delete pImage;
AppLogException("CreateItem failed with %s", GetErrorMessage(r));
return null;
}
}
bool urlFoundInBookmark = false;
-
- if(__pBookmarkList != null)
- {
- for (int i = 0; i < __pBookmarkList->GetCount();i++)
- {
- BookmarkData* pBookMark = dynamic_cast< BookmarkData* >(__pBookmarkList->GetAt(i));
- if(pBookMark != null && pHistory->GetHistoryUrl().CompareTo(pBookMark->GetUrl()) == 0)
- {
- urlFoundInBookmark = true;
- break;
- }
- }
- }
+//
+// if(__pBookmarkList != null)
+// {
+// for (int i = 0; i < __pBookmarkList->GetCount();i++)
+// {
+// BookmarkData* pBookMark = dynamic_cast< BookmarkData* >(__pBookmarkList->GetAt(i));
+// if(pBookMark != null && pHistory->GetHistoryUrl().CompareTo(pBookMark->GetUrl()) == 0)
+// {
+// urlFoundInBookmark = true;
+// break;
+// }
+// }
+// }
+ BookmarkPresentationModel::GetInstance()->DoesBookmarkExist(pHistory->GetHistoryUrl(),urlFoundInBookmark);
if (urlFoundInBookmark == true)
{
pBookmarkBitmap = AppResource::GetInstance()->GetBitmapN(IDB_ICON_BOOKMARK_ON_TEMP);
{
pBookmarkBitmap = AppResource::GetInstance()->GetBitmapN(IDB_ICON_BOOKMARK_OFF_TEMP);
}
- bookmarkBtnWidth = 64;
+ bookmarkBtnWidth = 74;
r = pItem->AddElement(Rectangle(104, 10, GetClientAreaBounds().width - 108 - 32 - bookmarkBtnWidth - 32, 60 - 44 + __fontSize), IDA_FORMAT_TITLE, pHistory->GetHistoryTitle(), __fontSize,CUSTOM_COLOR_TRANSPARENT,CUSTOM_COLOR_TRANSPARENT,CUSTOM_COLOR_TRANSPARENT,true);
CATCH:
delete pItem;
+ delete pImage;
return null;
}
// __pGroupedListView->UpdateList();
// }
- result r = GetHeader()->SetItemSelected(2);
+ result r = GetHeader()->SetItemSelected(1);
if (IsFailed(r))
{
- AppLog("HistoryListForm::OnSceneActivatedN header failed %ls", GetErrorMessage(r));
+ AppLog("HistoryListForm::OnSceneActivatedN header failed %s", GetErrorMessage(r));
return;
}
bool bookmarkFound = false;
BookmarkData* pBookMark = null;
- if(__pBookmarkList != null)
- {
- for (int i = 0; i < __pBookmarkList->GetCount(); i++)
- {
- pBookMark = dynamic_cast< BookmarkData* >(__pBookmarkList->GetAt(i));
- if (pBookMark != null && toggledUrl.CompareTo(pBookMark->GetUrl()) == 0)
- {
- bookmarkFound = true;
- break;
- }
- }
- }
+// if(__pBookmarkList != null)
+// {
+// for (int i = 0; i < __pBookmarkList->GetCount(); i++)
+// {
+// pBookMark = dynamic_cast< BookmarkData* >(__pBookmarkList->GetAt(i));
+// if (pBookMark != null && toggledUrl.CompareTo(pBookMark->GetUrl()) == 0)
+// {
+// bookmarkFound = true;
+// break;
+// }
+// }
+// }
+ BookmarkPresentationModel::GetInstance()->DoesBookmarkExist(toggledUrl,bookmarkFound);
if(bookmarkFound == false)
{
// Add the history in bookmark database
bookmark.SetBookmarkTitle(bookmarkTitle);
bookmark.SetUrl(pHistory->GetHistoryUrl());
bookmark.SetFaviconId(pHistory->GetFaviconId());
- bookmark.SetFavIconBuffer(*pHistory->GetFavIconBuffer());
+ if(pHistory->GetFavIconBuffer())
+ {
+ ByteBuffer *pBuffer = new ByteBuffer();
+
+ pBuffer->Construct(*pHistory->GetFavIconBuffer());
+ bookmark.SetFavIconBuffer(*pBuffer);
+ }
//r = BookmarkPresentationModel::GetInstance()->SaveBookmark(pBookmark);
r = BookmarkPresentationModel::GetInstance()->SaveTempBookmark(bookmark);
}
monthValue.Append(CommonUtil::GetString(L"IDS_COM_BODY_MAR"));
break;
case APRIL:
- monthValue.Append(CommonUtil::GetString(L"IDS_COM_BODY_APR"));
+ monthValue.Append(CommonUtil::GetString(L"IDS_COM_BODY_APRIL"));
break;
case MAY:
monthValue.Append(CommonUtil::GetString(L"IDS_COM_BODY_MAY"));
{
return;
}
- __pGroupedListView->UpdateList();
-
if (__pSearchListView != null)
{
r = __pSearchListView->SetBounds(Rectangle(0, 0, GetClientAreaBounds().width, __pGroupedListView->GetHeight()));