# -*- coding: UTF-8 -*-
#
# generated by wxGlade
#

import wx

# begin wxGlade: dependencies
import gettext
# end wxGlade

# begin wxGlade: extracode
from Gnumed.wxpython.gmEMRStructWidgets import cEpisodeSelectionPhraseWheel
# end wxGlade


class wxgMoveNarrativeDlg(wx.Dialog):
	def __init__(self, *args, **kwds):
		# begin wxGlade: wxgMoveNarrativeDlg.__init__
		kwds["style"] = kwds.get("style", 0) | wx.DEFAULT_DIALOG_STYLE | wx.MAXIMIZE_BOX | wx.MINIMIZE_BOX | wx.RESIZE_BORDER
		wx.Dialog.__init__(self, *args, **kwds)
		self.SetSize((500, 650))
		self.LBL_encounter = wx.StaticText(self, wx.ID_ANY, "")
		self.LBL_source_episode = wx.StaticText(self, wx.ID_ANY, "")
		self._PRW_episode_selector = cEpisodeSelectionPhraseWheel(self, wx.ID_ANY, "")
		self.LBL_narrative = wx.StaticText(self, wx.ID_ANY, "")
		self.__BTN_move = wx.Button(self, wx.ID_YES, _("Move"))
		self.__BTN_cancel = wx.Button(self, wx.ID_CANCEL, _("Cancel"))

		self.__set_properties()
		self.__do_layout()

		self.Bind(wx.EVT_BUTTON, self._on_move_button_pressed, id=wx.ID_YES)
		# end wxGlade

	def __set_properties(self):
		# begin wxGlade: wxgMoveNarrativeDlg.__set_properties
		self.SetTitle(_("Moving narrative to another episode"))
		self.SetSize((500, 650))
		self._PRW_episode_selector.SetToolTip(_("Select the episode you want to move the narrative to."))
		self._PRW_episode_selector.SetFocus()
		self.__BTN_move.SetToolTip(_("Move the narrative from the source to the target episode."))
		self.__BTN_cancel.SetToolTip(_("Cancel moving the narrative entries and leave them where they are."))
		self.__BTN_cancel.SetDefault()
		# end wxGlade

	def __do_layout(self):
		# begin wxGlade: wxgMoveNarrativeDlg.__do_layout
		__szr_main = wx.BoxSizer(wx.VERTICAL)
		__szr_buttons = wx.BoxSizer(wx.HORIZONTAL)
		__gszr_details = wx.FlexGridSizer(4, 2, 2, 5)
		__lbl_encounter = wx.StaticText(self, wx.ID_ANY, _("Encounter"))
		__gszr_details.Add(__lbl_encounter, 0, wx.ALIGN_CENTER_VERTICAL, 0)
		__gszr_details.Add(self.LBL_encounter, 1, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
		__lbl_source_episode = wx.StaticText(self, wx.ID_ANY, _("Source episode"))
		__lbl_source_episode.SetToolTip(_("The episode the displayed narrative currently belongs to."))
		__gszr_details.Add(__lbl_source_episode, 0, wx.ALIGN_CENTER_VERTICAL, 0)
		__gszr_details.Add(self.LBL_source_episode, 1, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
		__lbl_target_episode = wx.StaticText(self, wx.ID_ANY, _("Target episode"))
		__lbl_target_episode.SetToolTip(_("The episode you want to move the displayed narrative to."))
		__gszr_details.Add(__lbl_target_episode, 0, wx.ALIGN_CENTER_VERTICAL, 0)
		__gszr_details.Add(self._PRW_episode_selector, 1, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
		__lbl_narrative = wx.StaticText(self, wx.ID_ANY, _("Narrative"))
		__gszr_details.Add(__lbl_narrative, 0, 0, 0)
		__gszr_details.Add(self.LBL_narrative, 1, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND, 0)
		__gszr_details.AddGrowableRow(3)
		__gszr_details.AddGrowableCol(1)
		__szr_main.Add(__gszr_details, 1, wx.ALL | wx.EXPAND, 5)
		__szr_buttons.Add((20, 20), 1, wx.EXPAND, 0)
		__szr_buttons.Add(self.__BTN_move, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND | wx.RIGHT, 5)
		__szr_buttons.Add(self.__BTN_cancel, 0, wx.ALIGN_CENTER_VERTICAL | wx.EXPAND | wx.LEFT, 5)
		__szr_buttons.Add((20, 20), 1, wx.EXPAND, 0)
		__szr_main.Add(__szr_buttons, 0, wx.ALL | wx.EXPAND, 5)
		self.SetSizer(__szr_main)
		self.Layout()
		self.Centre()
		# end wxGlade

	def _on_move_button_pressed(self, event):  # wxGlade: wxgMoveNarrativeDlg.<event_handler>
		print("Event handler '_on_move_button_pressed' not implemented!")
		event.Skip()

# end of class wxgMoveNarrativeDlg
