<commit_before>import QtQuick 2.0
import Sailfish.Silica 1.0
import QtWebKit 3.0

Page
{
	id: page

    property int itemId;

    IconButton
    {
        id: deleteButton
        anchors.right: page.right
        icon.source: "image://Theme/icon-l-delete"
        onClicked: pocketManager.deleteItem (itemId);
    }

	IconButton
	{
		id: readButton
        anchors.right: deleteButton.left
		icon.source: pocketModel.IsRead (itemId) ?
            "image://Theme/icon-m-certificates":
            "image://Theme/icon-m-mail";
		onClicked:
			pocketManager.setRead (itemId, !pocketModel.IsRead (itemId));
	}

	IconButton
	{
		id: favoriteButton
		icon.source: pocketModel.IsFavorite (itemId) ?
            "image://Theme/icon-m-favorite-selected":
            "image://Theme/icon-m-favorite";
		anchors.right: readButton.left

		onClicked:
			pocketManager.setFavorite (itemId, !pocketModel.IsFavorite (itemId))
	}

	SilicaFlickable
	{
		clip: true
		anchors.top: readButton.bottom
		anchors.bottom: parent.bottom
		anchors.left: parent.left;
		anchors.right: parent.right
		contentWidth: view.width
		contentHeight: view.height

		WebView
		{
			id: view
			url: pocketModel.GetUrl (itemId);
            height: page.height
            width: page.width
		}

		VerticalScrollDecorator {}
		HorizontalScrollDecorator {}
	}
}<commit_msg>Replace IconButtons with PullDownMenu<commit_after>import QtQuick 2.0
import Sailfish.Silica 1.0
import QtWebKit 3.0

Page
{
	id: page

	property int itemId;

	RemorsePopup { id: remorse }


	SilicaFlickable
	{
		anchors.fill: parent

		PullDownMenu
		{
			MenuItem
			{
				text: "Delete";
				onClicked: remorse.execute ("Deleting", function () { pocketManager.deleteItem (itemId) })
			}

			MenuItem
			{
				id: readItem
				text: pocketModel.IsRead (itemId) ? "Set unread" : "Set read";
				onClicked: pocketManager.setRead (itemId, !pocketModel.IsRead (itemId));
			}

			MenuItem
			{
				id: favoriteItem
				text: pocketModel.IsFavorite (itemId) ? "Set unfavorite" : "Set favorite";
				onClicked: pocketManager.setFavorite (itemId, !pocketModel.IsFavorite (itemId))
			}
		}

		WebView
		{
			id: view
			url: pocketModel.GetUrl (itemId);
			height: page.height
			width: page.width
		}

		VerticalScrollDecorator {}
		HorizontalScrollDecorator {}
	}

	Connections
	{
		target: pocketModel
		onItemUpdated:
		{
			readItem.text = pocketModel.IsRead (itemId) ? "Set unread" : "Set read";
			favoriteItem.text = pocketModel.IsFavorite (itemId) ? "Set unfavorite" : "Set favorite";
		}
	}
}
{'fraction_non_alphanumeric': 0.11093564942755625, 'fraction_numerical': 0.00473746545598105, 'mean_word_length': 3.0544, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3053951', 'n_tokens_mistral': 987, 'n_tokens_neox': 861, 'n_words': 176}