~ubuntu-branches/ubuntu/precise/gnome-do/precise-proposed

« back to all changes in this revision

Viewing changes to Do/src/Do.Universe/SelectedTextItem.cs

  • Committer: Bazaar Package Importer
  • Author(s): Christopher James Halse Rogers
  • Date: 2008-09-14 10:09:40 UTC
  • mto: (0.1.8 sid)
  • mto: This revision was merged to the branch mainline in revision 7.
  • Revision ID: james.westby@ubuntu.com-20080914100940-kyghudg7py14bu2z
Tags: upstream-0.6.0.0
ImportĀ upstreamĀ versionĀ 0.6.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
19
19
 */
20
20
 
21
21
using System;
22
 
using System.Threading;
23
 
using System.Collections.Generic;
24
 
 
25
 
namespace Do.Universe
26
 
{
27
 
 
28
 
        public class SelectedTextItem : ITextItem
29
 
        {               
30
 
                public SelectedTextItem ()
31
 
                {
32
 
                }
33
 
                
34
 
                public string Name
35
 
                {
36
 
                        get { return "Selected text"; }
37
 
                }
38
 
                
39
 
                public string Description
40
 
                {
41
 
                        get { return "Currently selected text."; }
42
 
                }
43
 
                
44
 
                public string Icon
45
 
                {
 
22
using Mono.Unix;
 
23
 
 
24
namespace Do.Universe {
 
25
 
 
26
        public class SelectedTextItem : IProxyItem, ITextItem {         
 
27
                
 
28
                public IObject Inner {
 
29
                        get {
 
30
                                return new TextItem (Text);
 
31
                        }
 
32
                }
 
33
                
 
34
                public string Name {
 
35
                        get { return Catalog.GetString ("Selected text"); }
 
36
                }
 
37
                
 
38
                public string Description {
 
39
                        get { return Catalog.GetString ("Currently selected text."); }
 
40
                }
 
41
                
 
42
                public string Icon {
46
43
                        get { return "gtk-select-all"; }
47
44
                }
48
45
                
56
53
                                if (primary.WaitIsTextAvailable ()) {
57
54
                                        text = primary.WaitForText ();
58
55
                                } else {
59
 
                                        text = "";
 
56
                                        text = string.Empty;
60
57
                                }
61
58
                                return text;
62
59
                        }