profile: add edition in settings
- fix a small offset of the preference window when
switching between tabs
- increase sizes of photos to avoid pixelisation
Change-Id: Idfb9149a8de08c034dff3e42b41f5888bba893f7
Tuleap: #530
diff --git a/src/RingWizardWC.mm b/src/RingWizardWC.mm
index 569ffaf..1e4b7b3 100644
--- a/src/RingWizardWC.mm
+++ b/src/RingWizardWC.mm
@@ -39,6 +39,7 @@
#import "AppDelegate.h"
#import "Constants.h"
+#import "views/NSImage+Extensions.h"
#import "views/NSColor+RingTheme.h"
@implementation RingWizardWC {
@@ -156,7 +157,8 @@
if (auto profile = ProfileModel::instance().selectedProfile()) {
profile->person()->setFormattedName([[nicknameField stringValue] UTF8String]);
QPixmap p;
- if (p.loadFromData(QByteArray::fromNSData([[photoView image] TIFFRepresentation]))) {
+ auto smallImg = [NSImage imageResize:[photoView image] newSize:{100,100}];
+ if (p.loadFromData(QByteArray::fromNSData([smallImg TIFFRepresentation]))) {
profile->person()->setPhoto(QVariant(p));
}
profile->save();