Commit a740481b authored by Kateryna Kostiuk's avatar Kateryna Kostiuk

UI: fixes

- Buttons color and images.
- Record message UI during call.

Change-Id: I9a9ac7bfc3ef4923fe028371bb0040a0af7bfafa
parent 32cf6be8
......@@ -347,6 +347,7 @@ ${CMAKE_CURRENT_SOURCE_DIR}/data/dark/pending_contact_request.png
${CMAKE_CURRENT_SOURCE_DIR}/data/dark/ic_file_upload.png
${CMAKE_CURRENT_SOURCE_DIR}/data/dark/ic_record_stop.png
${CMAKE_CURRENT_SOURCE_DIR}/data/dark/ic_camera.png
${CMAKE_CURRENT_SOURCE_DIR}/data/dark/ic_audio_msg.png
${CMAKE_CURRENT_SOURCE_DIR}/data/light/ic_picture.png)
SET_SOURCE_FILES_PROPERTIES(${ring_ICONS} PROPERTIES
......
data/dark/ic_action_chat.png

1.17 KB | W: | H:

data/dark/ic_action_chat.png

184 Bytes | W: | H:

data/dark/ic_action_chat.png
data/dark/ic_action_chat.png
data/dark/ic_action_chat.png
data/dark/ic_action_chat.png
  • 2-up
  • Swipe
  • Onion skin
data/dark/ic_action_record.png

3.12 KB | W: | H:

data/dark/ic_action_record.png

234 Bytes | W: | H:

data/dark/ic_action_record.png
data/dark/ic_action_record.png
data/dark/ic_action_record.png
data/dark/ic_action_record.png
  • 2-up
  • Swipe
  • Onion skin
data/dark/ic_camera.png

875 Bytes | W: | H:

data/dark/ic_camera.png

640 Bytes | W: | H:

data/dark/ic_camera.png
data/dark/ic_camera.png
data/dark/ic_camera.png
data/dark/ic_camera.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -347,6 +347,8 @@ CVPixelBufferRef pixelBufferPreview;
[holdOnOffButton stopBlinkAnimation];
}
[self setUpButtons: currentCall isRecording: (callModel->isRecording([self getcallID]) || mediaModel->getAlwaysRecord())];
[videoView setShouldAcceptInteractions: currentCall.status == Status::IN_PROGRESS];
callStateLabel.stringValue = currentCall.status == Status::INCOMING_RINGING ? @"wants to talk to you" : @(to_string(currentCall.status).c_str());
loadingIndicator.hidden = (currentCall.status == Status::SEARCHING ||
......@@ -721,7 +723,6 @@ CVPixelBufferRef pixelBufferPreview;
[self mouseIsMoving: YES];
[loadingIndicator setAnimates:YES];
auto currentCall = callModel->getCall([self getcallID]);
[self setUpButtons: currentCall isRecording: (callModel->isRecording([self getcallID]) || mediaModel->getAlwaysRecord())];
[previewView setHidden: YES];
[self setUpPreviewFrame];
[self updatePendingCalls];
......
......@@ -973,9 +973,9 @@ typedef NS_ENUM(NSInteger, MessageSequencing) {
-(void) closeRecordingView {
if(recordMessagePopover != nil) {
recordingController.stopRecordingView;
[recordMessagePopover close];
recordMessagePopover = nil;
recordingController.stopRecordingView;
}
}
......
......@@ -251,7 +251,6 @@ previewView, timeLabel, recordOnOffButton, sendButton, fileImage, infoLabel, tim
[durationTimer invalidate];
durationTimer = nil;
[recordOnOffButton stopBlinkAnimation];
[self setInitialState];
}
-(void) disconnectVideo {
......@@ -301,6 +300,8 @@ previewView, timeLabel, recordOnOffButton, sendButton, fileImage, infoLabel, tim
timeLabel.textColor = color;
infoLabel.textColor = color;
NSString *title = NSLocalizedString(@"Send", @"Send button title");
NSString *info = NSLocalizedString(@"Press to start recording", @"Recording view explanation label");
infoLabel.stringValue = info;
NSMutableParagraphStyle *style = [[NSMutableParagraphStyle alloc] init];
[style setAlignment:NSCenterTextAlignment];
NSDictionary *attrsDictionary = [NSDictionary dictionaryWithObjectsAndKeys:color, NSForegroundColorAttributeName, style, NSParagraphStyleAttributeName, nil];
......@@ -360,6 +361,9 @@ previewView, timeLabel, recordOnOffButton, sendButton, fileImage, infoLabel, tim
[recordOnOffButton setHidden:YES];
infoLabel.textColor = [NSColor textColor];
[previewView setHidden:YES];
[sendButton setHidden:YES];
[fileImage setHidden:YES];
[timeLabel setStringValue: @""];
[self.view setFrameSize: CGSizeMake(370, 160)];
}
......
......@@ -55,7 +55,7 @@
self.mouseOutsideDarkColor = self.bgColor;
}
self.mouseOutsideColor = self.isDarkMode ? self.mouseOutsideDarkColor : self.mouseOutsideLightColor;
if(self.moiuseOutsideImageLightColor) {
if(!self.moiuseOutsideImageLightColor) {
self.moiuseOutsideImageLightColor = self.moiuseOutsideImageColor ? self.moiuseOutsideImageColor : self.imageLightColor;
}
if(!self.moiuseOutsideImageDarkColor) {
......@@ -92,7 +92,7 @@
}
if(self.imagePressedColor && self.pressed) {
self.imageColor = self.imagePressedColor;
} else if ( self.moiuseOutsideImageColor) {
} else if (self.moiuseOutsideImageColor) {
self.imageColor = self.moiuseOutsideImageColor;
}
if (self.imageIncreaseOnHover && self.enabled) {
......
......@@ -266,6 +266,7 @@ NSString* BLINK_ANIMATION_IDENTIFIER = @"blinkAnimation";
to:(NSColor*)endColor
scaleFactor:(CGFloat)scaleFactor
duration:(CGFloat) duration {
[self setWantsLayer: YES];
CIFilter *filter = [CIFilter filterWithName:@"CIFalseColor"];
[filter setDefaults];
[filter setValue:[CIColor colorWithRed:0.0 green:0.0 blue:0.0 alpha:1.0] forKey:@"inputColor0"];
......
......@@ -70,6 +70,12 @@
<userDefinedRuntimeAttribute type="number" keyPath="imageInsets">
<integer key="value" value="6"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="color" keyPath="imageColor">
<color key="value" red="0.99999600649999998" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="color" keyPath="imageDarkColor">
<color key="value" red="0.99999600649999998" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
<connections>
<action selector="hangUp:" target="-2" id="xfb-x5-yjW"/>
......
......@@ -345,7 +345,7 @@
<constraint firstAttribute="height" constant="32" id="2As-E1-3wN"/>
<constraint firstAttribute="width" constant="32" id="ThY-e2-Xwc"/>
</constraints>
<buttonCell key="cell" type="square" bezelStyle="shadowlessSquare" image="ic_action_audio" imagePosition="overlaps" alignment="center" transparent="YES" imageScaling="proportionallyDown" inset="2" id="1zm-4M-OeR">
<buttonCell key="cell" type="square" bezelStyle="shadowlessSquare" image="ic_audio_msg" imagePosition="overlaps" alignment="center" transparent="YES" imageScaling="proportionallyUpOrDown" inset="2" id="1zm-4M-OeR">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/>
</buttonCell>
......@@ -370,13 +370,20 @@
<action selector="startAudioMessage:" target="iH6-17-JsM" id="L0n-5l-pav"/>
</connections>
</button>
<customView translatesAutoresizingMaskIntoConstraints="NO" id="Pn0-gT-h4b">
<rect key="frame" x="34" y="29" width="4" height="2"/>
<constraints>
<constraint firstAttribute="height" constant="2" id="BuD-em-HlZ"/>
<constraint firstAttribute="width" constant="4" id="vfD-J4-Kv5"/>
</constraints>
</customView>
<button toolTip="Record a video message" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="B6d-Sc-UTp" customClass="HoverButton">
<rect key="frame" x="34" y="14" width="32" height="32"/>
<rect key="frame" x="40" y="14" width="32" height="32"/>
<constraints>
<constraint firstAttribute="height" constant="32" id="GRp-fA-Pkp"/>
<constraint firstAttribute="width" constant="32" id="f5f-YQ-2i3"/>
</constraints>
<buttonCell key="cell" type="square" bezelStyle="shadowlessSquare" image="ic_camera" imagePosition="overlaps" alignment="center" transparent="YES" imageScaling="proportionallyDown" inset="2" id="sjp-jf-vw1">
<buttonCell key="cell" type="square" bezelStyle="shadowlessSquare" image="ic_camera" imagePosition="overlaps" alignment="center" transparent="YES" imageScaling="proportionallyUpOrDown" inset="2" id="sjp-jf-vw1">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/>
</buttonCell>
......@@ -402,7 +409,7 @@
</connections>
</button>
<button toolTip="Send a file" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="gwx-eT-PcN" customClass="HoverButton">
<rect key="frame" x="68" y="14" width="32" height="32"/>
<rect key="frame" x="74" y="14" width="32" height="32"/>
<constraints>
<constraint firstAttribute="height" constant="32" id="C2W-wV-YvF"/>
<constraint firstAttribute="width" constant="32" id="zZF-4P-pW9"/>
......@@ -433,7 +440,7 @@
</connections>
</button>
<textField verticalCompressionResistancePriority="1000" allowsCharacterPickerTouchBarItem="YES" translatesAutoresizingMaskIntoConstraints="NO" id="bsk-Gj-qQ2">
<rect key="frame" x="100" y="22" width="526" height="17"/>
<rect key="frame" x="106" y="22" width="520" height="17"/>
<textFieldCell key="cell" lineBreakMode="charWrapping" selectable="YES" editable="YES" sendsActionOnEndEditing="YES" state="on" placeholderString="Send a message" id="Ilz-7v-2fr">
<font key="font" metaFont="system"/>
<color key="textColor" name="controlTextColor" catalog="System" colorSpace="catalog"/>
......@@ -532,6 +539,7 @@
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
</visibilityPriorities>
<customSpacing>
<real value="3.4028234663852886e+38"/>
......@@ -542,6 +550,7 @@
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
</customSpacing>
</stackView>
</subviews>
......@@ -724,13 +733,13 @@
</viewController>
</objects>
<resources>
<image name="ic_action_audio" width="36" height="36"/>
<image name="ic_action_call" width="72" height="72"/>
<image name="ic_action_cancel" width="72" height="72"/>
<image name="ic_action_send" width="72" height="72"/>
<image name="ic_action_video" width="72" height="72"/>
<image name="ic_arrow_back" width="72" height="72"/>
<image name="ic_camera" width="96" height="96"/>
<image name="ic_audio_msg" width="18" height="18"/>
<image name="ic_camera" width="18" height="18"/>
<image name="ic_file_upload" width="72" height="72"/>
<image name="ic_person_add" width="48" height="48"/>
</resources>
......
......@@ -356,8 +356,8 @@
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
</customView>
<stackView distribution="fill" orientation="horizontal" alignment="top" spacing="0.0" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Djs-L8-8Pe" userLabel="Controls">
<rect key="frame" x="219" y="20" width="308" height="44"/>
<stackView distribution="equalSpacing" orientation="horizontal" alignment="top" spacing="0.0" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Djs-L8-8Pe" userLabel="Controls">
<rect key="frame" x="217" y="20" width="312" height="44"/>
<subviews>
<button toolTip="Hang up" horizontalHuggingPriority="750" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="Kjq-iM-NBL" userLabel="Hang Up" customClass="HoverButton">
<rect key="frame" x="0.0" y="0.0" width="44" height="44"/>
......@@ -545,8 +545,15 @@
<action selector="toggleAddParticipantView:" target="-2" id="rhk-OI-z0Z"/>
</connections>
</button>
<customView translatesAutoresizingMaskIntoConstraints="NO" id="7oc-9E-B6q">
<rect key="frame" x="264" y="42" width="4" height="2"/>
<constraints>
<constraint firstAttribute="height" constant="2" id="2MR-E5-npg"/>
<constraint firstAttribute="width" constant="4" id="naC-cq-rWg"/>
</constraints>
</customView>
<button toolTip="Toggle chat" horizontalHuggingPriority="750" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="fmp-x4-Pef" userLabel="Chat" customClass="HoverButton">
<rect key="frame" x="264" y="0.0" width="44" height="44"/>
<rect key="frame" x="268" y="0.0" width="44" height="44"/>
<constraints>
<constraint firstAttribute="width" constant="44" id="48U-1h-yAx"/>
<constraint firstAttribute="height" constant="44" id="EDO-9c-ndD"/>
......@@ -557,7 +564,7 @@
</buttonCell>
<userDefinedRuntimeAttributes>
<userDefinedRuntimeAttribute type="number" keyPath="imageInsets">
<integer key="value" value="4"/>
<integer key="value" value="6"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="color" keyPath="imageColor">
<color key="value" red="0.84313725490196079" green="0.84313725490196079" blue="0.84313725490196079" alpha="1" colorSpace="calibratedRGB"/>
......@@ -585,6 +592,7 @@
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
</visibilityPriorities>
<customSpacing>
<real value="3.4028234663852886e+38"/>
......@@ -594,6 +602,7 @@
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
</customSpacing>
</stackView>
</subviews>
......@@ -1015,10 +1024,10 @@
<image name="ic_action_add_participant" width="72" height="72"/>
<image name="ic_action_audio" width="36" height="36"/>
<image name="ic_action_cancel" width="72" height="72"/>
<image name="ic_action_chat" width="100" height="100"/>
<image name="ic_action_chat" width="36" height="36"/>
<image name="ic_action_hangup" width="72" height="72"/>
<image name="ic_action_hold" width="72" height="72"/>
<image name="ic_action_record" width="100" height="100"/>
<image name="ic_action_record" width="36" height="36"/>
<image name="ic_action_send" width="72" height="72"/>
<image name="ic_action_video" width="72" height="72"/>
<image name="ic_file_upload" width="72" height="72"/>
......
......@@ -79,13 +79,13 @@
<color key="value" red="0.82471948862075806" green="0.37392586469650269" blue="0.32938593626022339" alpha="1" colorSpace="custom" customColorSpace="displayP3"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="color" keyPath="imageColor">
<color key="value" red="0.32584697008132935" green="0.32583719491958618" blue="0.32584273815155029" alpha="1" colorSpace="calibratedRGB"/>
<color key="value" red="0.2152817249" green="0.2152752876" blue="0.2152788937" alpha="1" colorSpace="calibratedRGB"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="color" keyPath="imageHoverColor">
<color key="value" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<color key="value" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</userDefinedRuntimeAttribute>
<userDefinedRuntimeAttribute type="color" keyPath="imageDarkColor">
<color key="value" red="0.32584697008132935" green="0.32583719491958618" blue="0.32584273815155029" alpha="1" colorSpace="calibratedRGB"/>
<color key="value" red="0.2152817249" green="0.2152752876" blue="0.2152788937" alpha="1" colorSpace="calibratedRGB"/>
</userDefinedRuntimeAttribute>
</userDefinedRuntimeAttributes>
<connections>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment