Ejemplo n.º 1
0
    private UploadFileChooserUI()
    {
        Glade.XML gxml = new Glade.XML(null, "organizer.glade", "filechooserdialog1", null);
        gxml.Autoconnect(this);
        _job           = new ThreadStart(ProcessThumbnail);
        _previewthread = new Thread(_job);

        label16.WidthRequest = eventbox7.WidthRequest;

        eventbox7.ModifyBg(Gtk.StateType.Normal, bgcolor);
        eventbox8.ModifyBg(Gtk.StateType.Normal, bgcolor);
        eventbox9.ModifyBg(Gtk.StateType.Normal, bgcolor);

        filechooserdialog1.Title = "Select files to upload";
        filechooserdialog1.SetIconFromFile(DeskFlickrUI.ICON_PATH);
        filechooserdialog1.SetFilename(PersistentInformation.GetInstance().UploadFilename);
        filechooserdialog1.SelectMultiple = true;

        FileFilter imagefilter = new FileFilter();

        imagefilter.AddMimeType("image/jpeg");
        imagefilter.AddMimeType("image/png");
        filechooserdialog1.Filter = imagefilter;

        filechooserdialog1.SelectionChanged += new EventHandler(OnFileSelectedChanged);
        filechooserdialog1.FileActivated    += new EventHandler(OnOpenButtonClicked);
        button10.Clicked += new EventHandler(OnOpenButtonClicked);
        button11.Clicked += new EventHandler(OnCancelButtonClicked);
        DeskFlickrUI.GetInstance().SetUploadWindow(false);
        filechooserdialog1.ShowAll();
    }