Exemple #1
0
        public AvatarPicker(ImageList avatarImageList, PersonSetting personSetting)
        {
            _okToClose       = true;
            _avatarImageList = avatarImageList;
            _personSetting   = personSetting;
            InitializeComponent();
            emailTextbox.Text = personSetting.Email;
            if (personSetting.Email != null)
            {
                _gravatar.SetImage(personSetting, avatarImageList);
                tabControl1.SelectedIndex = 1;
            }
            if (personSetting.AvatarImageName != null)
            {
                _croppedCustom.ImageLocation = Path.Combine(SirenOfShameSettings.GetAvatarsFolder(),
                                                            personSetting.AvatarImageName);
                tabControl1.SelectedIndex = 2;
            }
            int avatarCount = SirenOfShameSettings.AVATAR_COUNT;

            for (int i = 0; i < avatarCount; i++)
            {
                Avatar avatar = new Avatar();
                avatar.SetImage(i, avatarImageList);
                avatar.Click += AvatarOnClick;
                flowLayoutPanel1.Controls.Add(avatar);
            }
        }
 public AvatarPicker(ImageList avatarImageList, PersonSetting personSetting)
 {
     _imageService = new ImageService();
     _okToClose = true;
     _avatarImageList = avatarImageList;
     _personSetting = personSetting;
     InitializeComponent();
     emailTextbox.Text = personSetting.Email;
     if (personSetting.Email != null)
     {
         _gravatar.SetImage(personSetting, avatarImageList);
         tabControl1.SelectedIndex = 1;
     }
     if (personSetting.AvatarImageName != null)
     {
         _croppedCustom.ImageLocation = Path.Combine(SirenOfShameSettings.GetAvatarsFolder(),
             personSetting.AvatarImageName);
         tabControl1.SelectedIndex = 2;
     }
     int avatarCount = SirenOfShameSettings.AVATAR_COUNT;
     for (int i = 0; i < avatarCount; i++)
     {
         Avatar avatar = new Avatar();
         avatar.SetImage(i, avatarImageList);
         avatar.Click += AvatarOnClick;
         flowLayoutPanel1.Controls.Add(avatar);
     }
 }
Exemple #3
0
 public AvatarPicker(ImageList avatarImageList)
 {
     InitializeComponent();
     int avatarCount = SirenOfShameSettings.AVATAR_COUNT;
     for (int i = 0; i < avatarCount; i++)
     {
         Avatar avatar = new Avatar();
         avatar.SetImage(i, avatarImageList);
         avatar.Click += AvatarOnClick;
         flowLayoutPanel1.Controls.Add(avatar);
     }
 }
Exemple #4
0
        public AvatarPicker(ImageList avatarImageList)
        {
            InitializeComponent();
            int avatarCount = SirenOfShameSettings.AVATAR_COUNT;

            for (int i = 0; i < avatarCount; i++)
            {
                Avatar avatar = new Avatar();
                avatar.SetImage(i, avatarImageList);
                avatar.Click += AvatarOnClick;
                flowLayoutPanel1.Controls.Add(avatar);
            }
        }