[Monodevelop-patches-list] r672 - trunk/MonoDevelop/src/AddIns/DisplayBindings/SourceEditor/Gui

commit-watcher at mono-cvs.ximian.com commit-watcher at mono-cvs.ximian.com
Mon Jan 26 22:22:26 EST 2004


Author: benm
Date: 2004-01-26 22:22:26 -0500 (Mon, 26 Jan 2004)
New Revision: 672

Modified:
   trunk/MonoDevelop/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs
Log:
clipboard support

Modified: trunk/MonoDevelop/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs
===================================================================
--- trunk/MonoDevelop/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs	2004-01-27 03:10:26 UTC (rev 671)
+++ trunk/MonoDevelop/src/AddIns/DisplayBindings/SourceEditor/Gui/SourceEditorDisplayBinding.cs	2004-01-27 03:22:26 UTC (rev 672)
@@ -164,7 +164,10 @@
 		}
 		
 		public bool EnablePaste {
-			get { return true; }
+			get {
+				// TODO: how do i know if there is data?
+				return true;
+			}
 		}
 		
 		public bool EnableDelete {
@@ -177,14 +180,17 @@
 		
 		public void Cut (object sender, EventArgs e)
 		{
+			se.buffer.CutClipboard (clipboard, true);
 		}
 		
 		public void Copy (object sender, EventArgs e)
 		{
+			se.buffer.CopyClipboard (clipboard);
 		}
 		
 		public void Paste (object sender, EventArgs e)
 		{
+			se.buffer.PasteClipboard (clipboard);
 		}
 		
 		public void Delete (object sender, EventArgs e)
@@ -195,6 +201,8 @@
 		public void SelectAll (object sender, EventArgs e)
 		{
 		}
+		
+		Gtk.Clipboard clipboard = Gtk.Clipboard.Get (Gdk.Atom.Intern("CLIPBOARD", false));
 #endregion
 	}
 }




More information about the Monodevelop-patches-list mailing list