Skip to content
Snippets Groups Projects
Commit 9b91d223 authored by Kateryna Kostiuk's avatar Kateryna Kostiuk
Browse files

conversation: fix selection

Fix conversation selection after returning from account settings

Change-Id: I4ed05ef9896f9f0c3ad8e3e95cd4b5af32e3197d
parent 80e6d149
No related branches found
No related tags found
No related merge requests found
......@@ -52,6 +52,7 @@ typedef NS_ENUM(NSInteger, ViewState) {
SHOW_CONVERSATION_SCREEN,
SHOW_CALL_SCREEN,
SHOW_SETTINGS_SCREEN,
HIDE_SETTINGS_SCREEN,
LEAVE_MESSAGE,
};
......@@ -151,10 +152,6 @@ typedef NS_ENUM(NSInteger, ViewState) {
@catch (NSException *ex) {
return;
}
[welcomeContainer setHidden: YES];
[currentCallVC hideWithAnimation:false];
[currentCallVC.view removeFromSuperview];
[conversationVC hideWithAnimation:false];
[smartViewVC.view setHidden: YES];
[settingsVC show];
break;
......@@ -162,6 +159,10 @@ typedef NS_ENUM(NSInteger, ViewState) {
[conversationVC showWithAnimation: false];
[currentCallVC hideWithAnimation: false];
[conversationVC presentLeaveMessageView];
case HIDE_SETTINGS_SCREEN:
[self accountSettingsShouldOpen: NO];
[smartViewVC.view setHidden: NO];
[settingsVC hide];
default:
break;
}
......@@ -542,7 +543,7 @@ typedef NS_ENUM(NSInteger, ViewState) {
- (IBAction)openAccountSettings:(NSButton *)sender
{
[self changeViewTo: [settingsVC.view isHidden] ? SHOW_SETTINGS_SCREEN : SHOW_WELCOME_SCREEN];
[self changeViewTo: [settingsVC.view isHidden] ? SHOW_SETTINGS_SCREEN : HIDE_SETTINGS_SCREEN];
}
- (void) createNewAccount {
......
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14490.70" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="15705" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14490.70"/>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="15705"/>
<capability name="System colors introduced in macOS 10.14" minToolsVersion="10.0"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
......@@ -18,6 +18,13 @@
<rect key="frame" x="0.0" y="0.0" width="820" height="828"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
<subviews>
<button translatesAutoresizingMaskIntoConstraints="NO" id="aFy-fN-0gJ">
<rect key="frame" x="0.0" y="0.0" width="820" height="828"/>
<buttonCell key="cell" type="square" bezelStyle="shadowlessSquare" imagePosition="only" alignment="center" imageScaling="proportionallyUpOrDown" inset="2" id="VZg-RO-juK">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/>
</buttonCell>
</button>
<scrollView wantsLayer="YES" borderType="none" autohidesScrollers="YES" horizontalLineScroll="10" horizontalPageScroll="10" verticalLineScroll="10" verticalPageScroll="10" hasHorizontalScroller="NO" hasVerticalScroller="NO" usesPredominantAxisScrolling="NO" horizontalScrollElasticity="none" findBarPosition="aboveHorizontalRuler" translatesAutoresizingMaskIntoConstraints="NO" id="FE5-WQ-UWb">
<rect key="frame" x="0.0" y="0.0" width="820" height="828"/>
<clipView key="contentView" copiesOnScroll="NO" id="AS0-K7-DN3" customClass="CenteredClipView">
......@@ -83,11 +90,15 @@
</subviews>
<constraints>
<constraint firstItem="FE5-WQ-UWb" firstAttribute="leading" secondItem="Hz6-mo-xeY" secondAttribute="leading" id="0TU-rV-Feb"/>
<constraint firstItem="aFy-fN-0gJ" firstAttribute="leading" secondItem="Hz6-mo-xeY" secondAttribute="leading" id="9IA-A3-i70"/>
<constraint firstItem="cyq-zN-98i" firstAttribute="top" secondItem="Hz6-mo-xeY" secondAttribute="top" constant="30" id="DSp-Zd-np2"/>
<constraint firstItem="FE5-WQ-UWb" firstAttribute="centerX" secondItem="Hz6-mo-xeY" secondAttribute="centerX" id="Eod-1m-b43"/>
<constraint firstAttribute="trailing" secondItem="FE5-WQ-UWb" secondAttribute="trailing" id="Eoo-Ln-11S"/>
<constraint firstItem="FE5-WQ-UWb" firstAttribute="top" secondItem="Hz6-mo-xeY" secondAttribute="top" id="K1o-6r-aG8"/>
<constraint firstItem="aFy-fN-0gJ" firstAttribute="top" secondItem="Hz6-mo-xeY" secondAttribute="top" id="PGe-DE-2vR"/>
<constraint firstAttribute="bottom" secondItem="FE5-WQ-UWb" secondAttribute="bottom" id="V1A-Qu-x4s"/>
<constraint firstAttribute="bottom" secondItem="aFy-fN-0gJ" secondAttribute="bottom" id="ewE-um-z1z"/>
<constraint firstAttribute="trailing" secondItem="aFy-fN-0gJ" secondAttribute="trailing" id="hQ8-KI-Kkz"/>
<constraint firstItem="cyq-zN-98i" firstAttribute="leading" secondItem="Hz6-mo-xeY" secondAttribute="leading" constant="5" id="m4c-u7-L7d"/>
</constraints>
<point key="canvasLocation" x="139" y="267.5"/>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment