WKBackForwardList.cpp [plain text]
#include "config.h"
#include "WKBackForwardList.h"
#include "WebBackForwardList.h"
#include "WKAPICast.h"
using namespace WebKit;
WKTypeID WKBackForwardListGetTypeID()
{
return toAPI(WebBackForwardList::APIType);
}
WKBackForwardListItemRef WKBackForwardListGetCurrentItem(WKBackForwardListRef listRef)
{
return toAPI(toImpl(listRef)->currentItem());
}
WKBackForwardListItemRef WKBackForwardListGetBackItem(WKBackForwardListRef listRef)
{
return toAPI(toImpl(listRef)->backItem());
}
WKBackForwardListItemRef WKBackForwardListGetForwardItem(WKBackForwardListRef listRef)
{
return toAPI(toImpl(listRef)->forwardItem());
}
WKBackForwardListItemRef WKBackForwardListGetItemAtIndex(WKBackForwardListRef listRef, int index)
{
return toAPI(toImpl(listRef)->itemAtIndex(index));
}
unsigned WKBackForwardListGetBackListCount(WKBackForwardListRef listRef)
{
return toImpl(listRef)->backListCount();
}
unsigned WKBackForwardListGetForwardListCount(WKBackForwardListRef listRef)
{
return toImpl(listRef)->forwardListCount();
}
WKArrayRef WKBackForwardListCopyBackListWithLimit(WKBackForwardListRef listRef, unsigned limit)
{
return toAPI(toImpl(listRef)->backListAsImmutableArrayWithLimit(limit).releaseRef());
}
WKArrayRef WKBackForwardListCopyForwardListWithLimit(WKBackForwardListRef listRef, unsigned limit)
{
return toAPI(toImpl(listRef)->forwardListAsImmutableArrayWithLimit(limit).releaseRef());
}