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

using nispi.controlclass;

namespace nispi.Menu
{
    class MapControlViewMenu
    {
        public ContextMenuStripParts contextMenuStripParts;
        public ToolStripMenuItemParts menuItemOpenParts;
        public ToolStripMenuItemParts menuItemOpenNoPopUpParts;

        //サブメニュー
        public ToolStripMenuItemParts menuItemTimeParts;

        public ToolStripMenuItemParts menuItemDeleteLogParts;
        public ToolStripMenuItemParts menuItemOpenFolderParts;
        public ToolStripMenuItemParts menuItemUpdateParts;

        //時間のサブメニュー
        public ToolStripMenuItemParts menuItemTime30MinParts;
        public ToolStripMenuItemParts menuItemTime1HParts;
        public ToolStripMenuItemParts menuItemTime3HParts;
        public ToolStripMenuItemParts menuItemTime6HParts;
        public ToolStripMenuItemParts menuItemTime12HParts;
        public ToolStripMenuItemParts menuItemTime24HParts;

        public ToolStripMenuItemParts menuItemTime2DParts;
        public ToolStripMenuItemParts menuItemTime3DParts;

        public ToolStripMenuItemParts menuItemTime1WParts;
        public ToolStripMenuItemParts menuItemTime2WParts;

        public ToolStripMenuItemParts menuItemTime1MonParts;

        public MapControlViewMenuEvent mapControlViewMenuEvent;

        public MapControlViewMenu()
        {
            contextMenuStripParts = ContextMenuStripPartsManager.Pop();
            menuItemOpenParts = ToolStripMenuItemPartsManager.Pop();
            menuItemOpenNoPopUpParts = ToolStripMenuItemPartsManager.Pop();

            //サブメニュー
            menuItemTimeParts = ToolStripMenuItemPartsManager.Pop();

            menuItemDeleteLogParts = ToolStripMenuItemPartsManager.Pop();
            menuItemOpenFolderParts = ToolStripMenuItemPartsManager.Pop();
            menuItemUpdateParts = ToolStripMenuItemPartsManager.Pop();

            //時間のサブメニュー
            menuItemTime30MinParts = ToolStripMenuItemPartsManager.Pop();
            menuItemTime1HParts = ToolStripMenuItemPartsManager.Pop();
            menuItemTime3HParts = ToolStripMenuItemPartsManager.Pop();
            menuItemTime6HParts = ToolStripMenuItemPartsManager.Pop();
            menuItemTime12HParts = ToolStripMenuItemPartsManager.Pop();
            menuItemTime24HParts = ToolStripMenuItemPartsManager.Pop();

            menuItemTime2DParts = ToolStripMenuItemPartsManager.Pop();
            menuItemTime3DParts = ToolStripMenuItemPartsManager.Pop();

            menuItemTime1WParts = ToolStripMenuItemPartsManager.Pop();
            menuItemTime2WParts = ToolStripMenuItemPartsManager.Pop();

            menuItemTime1MonParts = ToolStripMenuItemPartsManager.Pop();

            //this.listViewPart = listViewPart;
            menuItemOpenParts.Text = "開く";

            menuItemOpenNoPopUpParts.Text = "ポップアップ無しで開く";

            menuItemTimeParts.Text = "時間を指定";

            menuItemDeleteLogParts.Text = "ログを削除";

            menuItemOpenFolderParts.Text = "該当するフォルダーを開く";

            menuItemUpdateParts.Text = "再読み込み";
            menuItemUpdateParts.Image = Resources.reload;

            contextMenuStripParts.ItemsAdd(menuItemOpenParts);
            contextMenuStripParts.ItemsAdd(menuItemOpenNoPopUpParts);
            contextMenuStripParts.ItemsAdd("-");
            //contextMenuStripParts.ItemsAdd(menuItemTimeParts);
            //contextMenuStripParts.ItemsAdd("-");
            contextMenuStripParts.ItemsAdd(menuItemDeleteLogParts);
            contextMenuStripParts.ItemsAdd(menuItemOpenFolderParts);
            contextMenuStripParts.ItemsAdd("-");
            contextMenuStripParts.ItemsAdd(menuItemUpdateParts);

            //時間の選択メニュー

            menuItemTime30MinParts.Text = "３０分以内";

            menuItemTime1HParts.Text = "１時間以内";

            menuItemTime3HParts.Text = "３時間以内";

            menuItemTime6HParts.Text = "６時間以内";

            menuItemTime12HParts.Text = "１２時間以内";

            menuItemTime24HParts.Text = "２４時間以内";

            menuItemTime2DParts.Text = "２日以内";

            menuItemTime3DParts.Text = "３日以内";

            menuItemTime1WParts.Text = "１週間以内";

            menuItemTime2WParts.Text = "２週間以内";

            menuItemTime1MonParts.Text = "１か月以内";

            menuItemTimeParts.DropDownItemsAdd(menuItemTime30MinParts);
            menuItemTimeParts.DropDownItemsAdd(menuItemTime1HParts);
            menuItemTimeParts.DropDownItemsAdd(menuItemTime3HParts);
            menuItemTimeParts.DropDownItemsAdd(menuItemTime6HParts);
            menuItemTimeParts.DropDownItemsAdd(menuItemTime12HParts);
            menuItemTimeParts.DropDownItemsAdd(menuItemTime24HParts);
            menuItemTimeParts.DropDownItemsAdd("-");

            menuItemTimeParts.DropDownItemsAdd(menuItemTime2DParts);
            menuItemTimeParts.DropDownItemsAdd(menuItemTime3DParts);
            menuItemTimeParts.DropDownItemsAdd("-");
            menuItemTimeParts.DropDownItemsAdd(menuItemTime1WParts);
            menuItemTimeParts.DropDownItemsAdd(menuItemTime2WParts);
            menuItemTimeParts.DropDownItemsAdd("-");
            menuItemTimeParts.DropDownItemsAdd(menuItemTime1MonParts);

            mapControlViewMenuEvent = new MapControlViewMenuEvent(this);
        }
    }
}