//ライセンス情報はAgeOnフォルダのLISENCEフォルダを参照してください
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using System.Windows.Forms;
using System.Diagnostics;
using System.Drawing;
using mshtml;
using nispi;

using nispi.controlclass;

namespace nispi.Menu
{
    class BrowserNumberMenu
    {
        public ContextMenuStripParts contextMenuStripParts;

        public ToolStripMenuItemParts menuItemWriteResParts;
        public ToolStripMenuItemParts menuItemWriteByResParts;
        public ToolStripMenuItemParts menuItemSetShioriParts;
        public ToolStripMenuItemParts menuItemOpenBrowserParts;
        public ToolStripMenuItemParts menuItemFrontTreeParts;
        public ToolStripMenuItemParts menuItemBackTreeParts;
        //public ToolStripMenuItemParts menuItemAllTreeParts;
        public ToolStripMenuItemParts menuItemExtractNameParts;
        public ToolStripMenuItemParts menuItemExtractIdParts;
        public ToolStripMenuItemParts menuItemCopyUrlParts;
        public ToolStripMenuItemParts menuItemCopyTitleParts;

        public NumberMenuEvent numberMenuEvent;

        public BrowserNumberMenu()
        {
            contextMenuStripParts = ContextMenuStripPartsManager.Pop();

            menuItemWriteResParts = ToolStripMenuItemPartsManager.Pop();
            menuItemWriteByResParts = ToolStripMenuItemPartsManager.Pop();
            menuItemSetShioriParts = ToolStripMenuItemPartsManager.Pop();
            menuItemOpenBrowserParts = ToolStripMenuItemPartsManager.Pop();
            menuItemFrontTreeParts = ToolStripMenuItemPartsManager.Pop();
            menuItemBackTreeParts = ToolStripMenuItemPartsManager.Pop();
            //menuItemAllTreeParts = ToolStripMenuItemPartsManager.Pop();
            menuItemExtractNameParts = ToolStripMenuItemPartsManager.Pop();
            menuItemExtractIdParts = ToolStripMenuItemPartsManager.Pop();
            menuItemCopyUrlParts = ToolStripMenuItemPartsManager.Pop();
            menuItemCopyTitleParts = ToolStripMenuItemPartsManager.Pop();

            menuItemWriteResParts.Text = "レスを書く(&V)";
            menuItemWriteByResParts.Text = "引用してレスを書く(&B)";
            menuItemSetShioriParts.Text = "しおりをセット(&S)";
            menuItemOpenBrowserParts.Text = "ブラウザで開く(&B)";
            menuItemFrontTreeParts.Text = "レスの前方をツリー表示(&F)";
            menuItemBackTreeParts.Text = "レスの後方をツリー表示(&A)";
            //menuItemAllTreeParts.Text = "レスに関連する全体をツリー表示";
            menuItemExtractNameParts.Text = "名前でレスを抽出(&Z)";
            menuItemExtractIdParts.Text = "IDでレスを抽出(&X)";
            menuItemCopyUrlParts.Text = "URLをコピー(&C)";
            menuItemCopyTitleParts.Text = "タイトルをコピー(&T)";

            contextMenuStripParts.ItemsAdd(menuItemWriteResParts);
            //contextMenuStripParts.ItemsAdd(menuItemWriteByResParts);
            contextMenuStripParts.ItemsAdd("-");
            contextMenuStripParts.ItemsAdd(menuItemSetShioriParts);
            contextMenuStripParts.ItemsAdd("-");
            contextMenuStripParts.ItemsAdd(menuItemOpenBrowserParts);
            contextMenuStripParts.ItemsAdd("-");
            contextMenuStripParts.ItemsAdd(menuItemFrontTreeParts);
            contextMenuStripParts.ItemsAdd(menuItemBackTreeParts);
            //contextMenuStripParts.ItemsAdd(menuItemAllTreeParts);
            contextMenuStripParts.ItemsAdd("-");
            contextMenuStripParts.ItemsAdd(menuItemExtractNameParts);
            contextMenuStripParts.ItemsAdd(menuItemExtractIdParts);
            contextMenuStripParts.ItemsAdd("-");
            contextMenuStripParts.ItemsAdd(menuItemCopyUrlParts);
            contextMenuStripParts.ItemsAdd(menuItemCopyTitleParts);

            SetEvent();
        }

        public void SetEvent()
        {
            this.numberMenuEvent = new NumberMenuEvent(this);
        }
    }
}