Ejemplo n.º 1
0
        /// -----------------------------------------------------------------------------------
        /// <summary>
        /// Executes in two distinct scenarios.
        ///
        /// 1. If disposing is true, the method has been called directly
        /// or indirectly by a user's code via the Dispose method.
        /// Both managed and unmanaged resources can be disposed.
        ///
        /// 2. If disposing is false, the method has been called by the
        /// runtime from inside the finalizer and you should not reference (access)
        /// other managed objects, as they already have been garbage collected.
        /// Only unmanaged resources can be disposed.
        /// </summary>
        /// <param name="disposing"></param>
        /// <remarks>
        /// If any exceptions are thrown, that is fine.
        /// If the method is being done in a finalizer, it will be ignored.
        /// If it is thrown by client code calling Dispose,
        /// it needs to be handled by fixing the bug.
        ///
        /// If subclasses override this method, they should call the base implementation.
        /// </remarks>
        /// -----------------------------------------------------------------------------------
        protected override void Dispose(bool disposing)
        {
            //Debug.WriteLineIf(!disposing, "****************** " + GetType().Name + " 'disposing' is false. ******************");
            // Must not be run more than once.
            if (IsDisposed)
            {
                return;
            }

            if (disposing)
            {
                // Dispose managed resources here.
                if (m_footnoteForm != null)
                {
                    m_footnoteForm.Dispose();
                }
            }

            // Dispose unmanaged resources here, whether disposing is true or false.
            m_footnoteForm = null;
            m_footnoteView = null;             // m_footnoteForm made it, and disposes it.
            m_genesis      = null;

            base.Dispose(disposing);
        }
Ejemplo n.º 2
0
        /// -----------------------------------------------------------------------------------
        /// <summary>
        /// Close the footnote view
        /// </summary>
        /// -----------------------------------------------------------------------------------
        public override void TestTearDown()
        {
            m_footnoteView = null;             // m_footnoteForm made it, and disposes it.
            m_footnoteForm.Close();            // This should also dispose it.
            m_footnoteForm = null;
            m_Jude         = null;

            base.TestTearDown();             // If it isn't last, we get some C++ error
        }
Ejemplo n.º 3
0
		/// -----------------------------------------------------------------------------------
		/// <summary>
		/// Close the footnote view
		/// </summary>
		/// -----------------------------------------------------------------------------------
		public override void TestTearDown()
		{
			m_footnoteView = null; // m_footnoteForm made it, and disposes it.
			m_footnoteForm.Close(); // This should also dispose it.
			m_footnoteForm = null;
			m_Jude = null;

			base.TestTearDown(); // If it isn't last, we get some C++ error
		}
Ejemplo n.º 4
0
        public override void Exit()
        {
            CheckDisposed();

            m_footnoteView = null;             // m_footnoteForm made it, and disposes it.
            m_footnoteForm.Close();            // This should also dispose it.
            m_footnoteForm = null;

            base.Exit();             // If it isn't last, we get some C++ error
        }
Ejemplo n.º 5
0
		public void Init()
		{
			m_footnoteForm = new DummyFootnoteViewForm();
			m_footnoteForm.DeleteRegistryKey();
			m_footnoteForm.CreateFootnoteView();

			//Application.DoEvents();
			m_footnoteForm.Show();
			m_footnoteView = m_footnoteForm.FootnoteView;
			m_cache = m_footnoteForm.Cache;
			IScripture scr = m_cache.LangProject.TranslatedScriptureOA;
			Application.DoEvents();
		}
Ejemplo n.º 6
0
        /// -----------------------------------------------------------------------------------
        /// <summary>
        /// Create a new footnote view
        /// </summary>
        /// -----------------------------------------------------------------------------------
        public override void TestSetup()
        {
            base.TestSetup();

            m_footnoteForm = new DummyFootnoteViewForm();
            m_footnoteForm.DeleteRegistryKey();
            m_footnoteForm.CreateFootnoteView(Cache);

            //Application.DoEvents();
            m_footnoteForm.Show();
            m_footnoteView = m_footnoteForm.FootnoteView;
            m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
            m_scr.RestartFootnoteSequence = true;
            Application.DoEvents();
        }
Ejemplo n.º 7
0
		/// -----------------------------------------------------------------------------------
		/// <summary>
		/// Create a new footnote view
		/// </summary>
		/// -----------------------------------------------------------------------------------
		public override void TestSetup()
		{
			base.TestSetup();

			m_footnoteForm = new DummyFootnoteViewForm();
			m_footnoteForm.DeleteRegistryKey();
			m_footnoteForm.CreateFootnoteView(Cache);

			//Application.DoEvents();
			m_footnoteForm.Show();
			m_footnoteView = m_footnoteForm.FootnoteView;
			m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
			m_scr.RestartFootnoteSequence = true;
			Application.DoEvents();
		}
Ejemplo n.º 8
0
        public override void Initialize()
        {
            CheckDisposed();
            base.Initialize();

            m_scrInMemoryCache.InitializeWritingSystemEncodings();
            m_footnoteForm = new DummyFootnoteViewForm();
            m_footnoteForm.DeleteRegistryKey();
            m_footnoteForm.CreateFootnoteView(Cache);

            Application.DoEvents();
            m_footnoteForm.Show();
            m_footnoteView = m_footnoteForm.FootnoteView;
            m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
            m_scr.RestartFootnoteSequence  = true;
            m_scr.DisplayFootnoteReference = true;
            Application.DoEvents();
        }
        /// -----------------------------------------------------------------------------------
        /// <summary>
        /// Create a new footnote view
        /// </summary>
        /// -----------------------------------------------------------------------------------
        public override void TestSetup()
        {
            base.TestSetup();

            m_scr.CrossRefsCombinedWithFootnotes = true;
            m_scr.FootnoteMarkerType             = FootnoteMarkerTypes.SymbolicFootnoteMarker;
            m_scr.FootnoteMarkerSymbol           = "#";
            m_scr.DisplayFootnoteReference       = true;

            m_footnoteForm = new DummyFootnoteViewForm();
            m_footnoteForm.DeleteRegistryKey();
            m_footnoteForm.CreateFootnoteView(Cache);

            m_footnoteForm.Show();
            m_footnoteView = m_footnoteForm.FootnoteView;
            m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
            Application.DoEvents();
        }
		/// -----------------------------------------------------------------------------------
		/// <summary>
		/// Create a new footnote view
		/// </summary>
		/// -----------------------------------------------------------------------------------
		public override void TestSetup()
		{
			base.TestSetup();

			m_scr.CrossRefsCombinedWithFootnotes = true;
			m_scr.FootnoteMarkerType = FootnoteMarkerTypes.SymbolicFootnoteMarker;
			m_scr.FootnoteMarkerSymbol = "#";
			m_scr.DisplayFootnoteReference = true;

			m_footnoteForm = new DummyFootnoteViewForm();
			m_footnoteForm.DeleteRegistryKey();
			m_footnoteForm.CreateFootnoteView(Cache);

			m_footnoteForm.Show();
			m_footnoteView = m_footnoteForm.FootnoteView;
			m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
			Application.DoEvents();
		}
		/// <summary>
		/// Executes in two distinct scenarios.
		///
		/// 1. If disposing is true, the method has been called directly
		/// or indirectly by a user's code via the Dispose method.
		/// Both managed and unmanaged resources can be disposed.
		///
		/// 2. If disposing is false, the method has been called by the
		/// runtime from inside the finalizer and you should not reference (access)
		/// other managed objects, as they already have been garbage collected.
		/// Only unmanaged resources can be disposed.
		/// </summary>
		/// <param name="disposing"></param>
		/// <remarks>
		/// If any exceptions are thrown, that is fine.
		/// If the method is being done in a finalizer, it will be ignored.
		/// If it is thrown by client code calling Dispose,
		/// it needs to be handled by fixing the bug.
		///
		/// If subclasses override this method, they should call the base implementation.
		/// </remarks>
		protected override void Dispose(bool disposing)
		{
			//Debug.WriteLineIf(!disposing, "****************** " + GetType().Name + " 'disposing' is false. ******************");
			// Must not be run more than once.
			if (IsDisposed)
				return;

			if (disposing)
			{
				// Dispose managed resources here.
				if (m_footnoteForm != null)
					m_footnoteForm.Dispose();
			}

			// Dispose unmanaged resources here, whether disposing is true or false.
			m_footnoteView = null; // m_footnoteForm made it, and disposes it.
			m_footnoteForm = null;

			base.Dispose(disposing);
		}
Ejemplo n.º 12
0
        public override void Initialize()
        {
            CheckDisposed();
            base.Initialize();

            m_scrInMemoryCache.InitializeWritingSystemEncodings();
            m_scr.CrossRefsCombinedWithFootnotes = true;
            m_scr.FootnoteMarkerType             = FootnoteMarkerTypes.SymbolicFootnoteMarker;
            m_scr.FootnoteMarkerSymbol           = "#";
            m_scr.DisplayFootnoteReference       = true;

            m_footnoteForm = new DummyFootnoteViewForm();
            m_footnoteForm.DeleteRegistryKey();
            m_footnoteForm.CreateFootnoteView(Cache);

            m_footnoteForm.Show();
            m_footnoteView = m_footnoteForm.FootnoteView;
            m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
            Application.DoEvents();
        }
Ejemplo n.º 13
0
		public override void Initialize()
		{
			CheckDisposed();
			base.Initialize();

			m_scrInMemoryCache.InitializeWritingSystemEncodings();
			m_wsUrdu = InMemoryFdoCache.s_wsHvos.Ur;

			m_footnoteForm = new DummyFootnoteViewForm();
			m_footnoteForm.DeleteRegistryKey();
			m_footnoteForm.CreateFootnoteView(Cache);

			//Application.DoEvents();
			m_footnoteForm.Show();
			m_footnoteView = m_footnoteForm.FootnoteView;
			m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
			m_scr.RestartFootnoteSequence = true;
			Application.DoEvents();
		}
Ejemplo n.º 14
0
		public override void Exit()
		{
			CheckDisposed();

			m_footnoteView = null; // m_footnoteForm made it, and disposes it.
			m_footnoteForm.Close(); // This should also dispose it.
			m_footnoteForm = null;
			m_genesis = null;

			base.Exit(); // If it isn't last, we get some C++ error
		}
Ejemplo n.º 15
0
		public void CleanUp()
		{
			if (m_cache != null)
			{
				if (m_cache.CanUndo)
					m_cache.Undo();
				if (m_cache.DatabaseAccessor.IsTransactionOpen())
					m_cache.DatabaseAccessor.RollbackTrans();
			}
			else
			{
				Debug.WriteLine("Null cache in cleanup, something went wrong.");
			}
			m_cache = null;
			m_footnoteView = null;
			m_footnoteForm.Close();
			m_footnoteForm = null;
		}
Ejemplo n.º 16
0
        /// -----------------------------------------------------------------------------------
        /// <summary>
        /// Create a new footnote view
        /// </summary>
        /// -----------------------------------------------------------------------------------
        public override void TestSetup()
        {
            base.TestSetup();
            m_footnoteForm = new DummyFootnoteViewForm();
            m_footnoteForm.DeleteRegistryKey();
            m_footnoteForm.CreateFootnoteView(Cache);

            //Application.DoEvents();
            m_footnoteForm.Show();
            m_footnoteView = m_footnoteForm.FootnoteView;
            Application.DoEvents();
        }
Ejemplo n.º 17
0
 /// -----------------------------------------------------------------------------------
 /// <summary>
 /// Close the footnote view
 /// </summary>
 /// -----------------------------------------------------------------------------------
 public override void TestTearDown()
 {
     m_footnoteView = null;
     m_footnoteForm.Close();
     m_footnoteForm = null;
     base.TestTearDown();
 }
		public override void Initialize()
		{
			CheckDisposed();
			base.Initialize();

			m_scrInMemoryCache.InitializeWritingSystemEncodings();
			m_scr.CrossRefsCombinedWithFootnotes = true;
			m_scr.FootnoteMarkerType = FootnoteMarkerTypes.SymbolicFootnoteMarker;
			m_scr.FootnoteMarkerSymbol = "#";
			m_scr.DisplayFootnoteReference = true;

			m_footnoteForm = new DummyFootnoteViewForm();
			m_footnoteForm.DeleteRegistryKey();
			m_footnoteForm.CreateFootnoteView(Cache);

			m_footnoteForm.Show();
			m_footnoteView = m_footnoteForm.FootnoteView;
			m_footnoteView.RootBox.MakeSimpleSel(true, true, false, true);
			Application.DoEvents();
		}