public TwitPicOptionsForm(TwitPicSettings settings)
        {
            InitializeComponent();

            _settings = settings;
            this.txtAccessToken.Text         = _settings.AccessToken;
            this.txtAccessSecret.Text        = _settings.AccessSecret;
            this.cmbImageFormat.SelectedItem = settings.ImageFormat;
            this.qualitySlider.Value         = _settings.JpgImageQuality;
            this.chkTweet.Checked            = _settings.Tweet;
            this.chkPopBrowser.Checked       = _settings.PopBrowser;
            HandleQualitySliderValueChanged(null, null);
            SelectedImageFormatChanged(null, null);

            // only makes sense to clear settings if they are not clear yet.
            this.btnClear.Enabled = (!String.IsNullOrEmpty(_settings.AccessToken) ||
                                     !String.IsNullOrEmpty(_settings.AccessSecret));
        }
Example #2
0
        public TwitPicOptionsForm(TwitPicSettings settings)
        {
            InitializeComponent();

            _settings                        = settings;
            this.txtAccessToken.Text         = _settings.AccessToken;
            this.txtAccessSecret.Text        = _settings.AccessSecret;
            this.cmbImageFormat.SelectedItem = settings.ImageFormat;
            this.qualitySlider.Value         = _settings.JpgImageQuality;
            this.chkTweet.Checked            = _settings.Tweet;
            this.chkPopBrowser.Checked       = _settings.PopBrowser;
            HandleQualitySliderValueChanged(null,null);
            SelectedImageFormatChanged(null,null);

            // only makes sense to clear settings if they are not clear yet.
            this.btnClear.Enabled = (!String.IsNullOrEmpty(_settings.AccessToken) ||
                                       !String.IsNullOrEmpty(_settings.AccessSecret));
        }
Example #3
0
 public void StoreTokens(TwitPicSettings s)
 {
     s.AccessToken  = this._oauth["token"];
     s.AccessSecret = this._oauth["token_secret"];
 }
Example #4
0
 public void StoreTokens(TwitPicSettings s)
 {
     s.AccessToken = this._oauth["token"];
     s.AccessSecret = this._oauth["token_secret"];
 }