Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/mpc-hc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCasimir666 <casimir666@users.sourceforge.net>2009-03-28 15:44:56 +0300
committerCasimir666 <casimir666@users.sourceforge.net>2009-03-28 15:44:56 +0300
commit0e677f6b9b7ed77d77673a3a035908606bdcb2ae (patch)
tree49ee57e2d6a93e43b5039837e9d6f3ed3f3177ab /src/apps/mplayerc/EditListEditor.h
parentf6d550b9b9da6d66666e0659692ba8a2d61738fe (diff)
Added : EDL editor
Changed : Improved speed for step frame forward git-svn-id: https://mpc-hc.svn.sourceforge.net/svnroot/mpc-hc/trunk@1022 10f7b99b-c216-0410-bff0-8a66a9350fd8
Diffstat (limited to 'src/apps/mplayerc/EditListEditor.h')
-rw-r--r--src/apps/mplayerc/EditListEditor.h97
1 files changed, 97 insertions, 0 deletions
diff --git a/src/apps/mplayerc/EditListEditor.h b/src/apps/mplayerc/EditListEditor.h
new file mode 100644
index 000000000..5f9f9bb8c
--- /dev/null
+++ b/src/apps/mplayerc/EditListEditor.h
@@ -0,0 +1,97 @@
+/*
+ * $Id$
+ *
+ * (C) 2006-2007 see AUTHORS
+ *
+ * This file is part of mplayerc.
+ *
+ * Mplayerc is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * Mplayerc is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+
+#pragma once
+#include "PlayerListCtrl.h"
+
+
+class CClip
+{
+private :
+ REFERENCE_TIME m_rtIn;
+ REFERENCE_TIME m_rtOut;
+public :
+
+ CClip();
+
+ bool HaveIn() { return m_rtIn != _I64_MIN; };
+ bool HaveOut() { return m_rtOut != _I64_MIN; };
+
+ void SetOut (LPCTSTR strVal);
+ void SetIn (LPCTSTR strVal);
+ void SetIn (REFERENCE_TIME rtVal);
+ void SetOut (REFERENCE_TIME rtVal);
+
+ CString GetIn();
+ CString GetOut();
+};
+
+class CEditListEditor : public CSizingControlBarG
+{
+ DECLARE_DYNAMIC(CEditListEditor)
+
+ enum {COL_INDEX, COL_IN, COL_OUT, COL_MAX};
+
+ CPlayerListCtrl m_list;
+ CImageList m_fakeImageList;
+ POSITION m_CurPos;
+ BOOL m_bDragging;
+ int m_nDragIndex;
+ int m_nDropIndex;
+ CPoint m_ptDropPoint;
+ CImageList* m_pDragImage;
+
+ CString m_strFileName;
+ bool m_bFileOpen;
+ CList<CClip> m_EditList;
+
+ void SaveEditListToFile();
+ void ResizeListColumn();
+ POSITION InsertClip(POSITION pos, CClip& NewClip);
+ void DropItemOnList();
+ int FindIndex(POSITION pos);
+
+protected :
+ DECLARE_MESSAGE_MAP()
+
+public:
+ CEditListEditor(void);
+ ~CEditListEditor(void);
+
+ BOOL Create(CWnd* pParentWnd);
+
+ void CloseFile();
+ void OpenFile(LPCTSTR lpFileName);
+ void SetIn (REFERENCE_TIME rtIn);
+ void SetOut (REFERENCE_TIME rtOut);
+ void NewClip (REFERENCE_TIME rtVal);
+
+ afx_msg void OnSize(UINT nType, int cx, int cy);
+ afx_msg void OnLvnKeyDown(NMHDR* pNMHDR, LRESULT* pResult);
+ afx_msg void OnDrawItem(int nIDCtl, LPDRAWITEMSTRUCT lpDrawItemStruct);
+ afx_msg void OnLvnItemchanged(NMHDR *pNMHDR, LRESULT *pResult);
+ afx_msg void OnBeginDrag(NMHDR* pNMHDR, LRESULT* pResult);
+ afx_msg void OnMouseMove(UINT nFlags, CPoint point);
+ afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
+ afx_msg void OnTimer(UINT_PTR nIDEvent);
+};