Beispiel #1
0
        public FirstRunDialog()
        {
            this.Title = Catalog.GetString("Last.fm Account Details");
            this.HasSeparator = false;
            this.Modal = true;

            Glade.XML glade_xml = new Glade.XML (null, "FirstRunDialog.glade", "first_run_contents", null);
            glade_xml.Autoconnect (this);
            this.VBox.Add (first_run_contents);

            // FIXME: Use stock?
            this.AddButton ("gtk-quit", ResponseType.Reject);
            startplayer = this.AddButton (Catalog.GetString("Start Player"), ResponseType.Ok);
            startplayer.Sensitive = false;
            signup_button = new Gnome.HRef ("http://www.last.fm/signup.php",
                            Catalog.GetString("Sign up for Last.fm"));
            signup_container.Add (signup_button);
            signup_button.Visible = true;

            password_entry = new IconEntry ();
            password_entry.Visibility = false;
            password_entry.Visible = true;
            // This is the bullet char...
            password_entry.InvisibleChar = '•';
            password_entry.SetIcon (IconEntryPosition.Primary,
                        new Image (null, "secure.png"));

            // EventHandlers to give more sensitive interface
            password_entry.Activated += new EventHandler (OnEnter);
            password_entry.Changed += new EventHandler (OnEntryChange);
            username_entry.Changed += new EventHandler (OnEntryChange);

            password_container.Add (password_entry);

            first_run_contents.Visible = true;
        }
Beispiel #2
0
        private void SetupUI()
        {
            search_combo = ComboBox.NewText ();
            search_combo.AppendText (Catalog.GetString("Music that sounds like"));
            search_combo.AppendText (Catalog.GetString("Music that is tagged as"));
            search_combo.AppendText (Catalog.GetString("A neighbours station"));
            search_combo.AppendText (Catalog.GetString("A users station"));
            search_combo.AppendText (Catalog.GetString("Music from fans of"));
            search_combo.AppendText (Catalog.GetString("A group station"));
            search_combo.Active = 0;

            search_combo.Visible = true;

            search_combo_container.Add (search_combo);

            search_combo.Changed += new EventHandler (OnComboChanged);

            search_entry = new IconEntry ();
            search_entry.Visible = true;
            search_entry.AddClearButton ();
            search_entry_container.Add (search_entry);

            search_entry.Changed += new EventHandler (OnSearchChanged);
            search_entry.Activated += new EventHandler (OnSearchClicked);
            search_button.Clicked += new EventHandler (OnSearchClicked);

            band_image = new Image ();
            band_image.Visible = true;
            image_container.Add (band_image);

            tagview = new TagView ();
            tagview.Visible = true;
            tag_container.Add (tagview);
        }