Alexandre Lision | 8521baa | 2015-03-13 11:08:00 -0400 | [diff] [blame] | 1 | /* |
Alexandre Lision | 9fe374b | 2016-01-06 10:17:31 -0500 | [diff] [blame] | 2 | * Copyright (C) 2015-2016 Savoir-faire Linux Inc. |
Alexandre Lision | 8521baa | 2015-03-13 11:08:00 -0400 | [diff] [blame] | 3 | * Author: Alexandre Lision <alexandre.lision@savoirfairelinux.com> |
| 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation; either version 3 of the License, or |
| 8 | * (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this program; if not, write to the Free Software |
| 17 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
Alexandre Lision | 8521baa | 2015-03-13 11:08:00 -0400 | [diff] [blame] | 18 | */ |
Alexandre Lision | 5855b6a | 2015-02-03 11:31:05 -0500 | [diff] [blame] | 19 | #import <Cocoa/Cocoa.h> |
Kateryna Kostiuk | ecaa395 | 2018-07-13 16:00:34 -0400 | [diff] [blame] | 20 | #import "LrcModelsProtocol.h" |
Kateryna Kostiuk | 1f8c125 | 2018-07-30 18:18:57 -0400 | [diff] [blame] | 21 | #import "ChooseAccountVC.h" |
Kateryna Kostiuk | 133364b | 2018-10-31 11:36:08 -0400 | [diff] [blame] | 22 | #import "CurrentCallVC.h" |
Alexandre Lision | 5855b6a | 2015-02-03 11:31:05 -0500 | [diff] [blame] | 23 | |
Anthony Léonard | 9bebf1d | 2017-12-21 14:33:51 -0500 | [diff] [blame] | 24 | namespace lrc { |
| 25 | namespace api { |
| 26 | namespace account { |
| 27 | struct Info; |
| 28 | } |
| 29 | } |
| 30 | } |
| 31 | |
Kateryna Kostiuk | 5d90c3b | 2019-07-18 12:03:52 -0400 | [diff] [blame] | 32 | @interface RingWindowController : NSWindowController <NSSharingServicePickerDelegate, ChooseAccountDelegate, LrcModelsProtocol, CallViewControllerDelegate,NSWindowDelegate> { |
Alexandre Lision | 4a7b95e | 2015-02-20 10:06:43 -0500 | [diff] [blame] | 33 | IBOutlet NSView *currentView; |
Alexandre Lision | 5855b6a | 2015-02-03 11:31:05 -0500 | [diff] [blame] | 34 | } |
| 35 | |
Kateryna Kostiuk | a724846 | 2017-04-18 16:15:31 -0400 | [diff] [blame] | 36 | /** |
| 37 | * KVO to show or hide some UI elements in RingWindow: |
| 38 | * - Share button |
| 39 | * - QRCode |
Kateryna Kostiuk | a724846 | 2017-04-18 16:15:31 -0400 | [diff] [blame] | 40 | * - Explanatory label |
| 41 | */ |
Kateryna Kostiuk | ab499f4 | 2018-04-16 12:27:33 -0400 | [diff] [blame] | 42 | @property (nonatomic) BOOL notRingAccount; |
| 43 | /** |
| 44 | * KVO to show or hide ringIDLabel |
| 45 | */ |
| 46 | @property (nonatomic) BOOL isSIPAccount; |
| 47 | |
Kateryna Kostiuk | a724846 | 2017-04-18 16:15:31 -0400 | [diff] [blame] | 48 | |
Alexandre Lision | 4a7b95e | 2015-02-20 10:06:43 -0500 | [diff] [blame] | 49 | - (IBAction)openPreferences:(id)sender; |
Alexandre Lision | 5855b6a | 2015-02-03 11:31:05 -0500 | [diff] [blame] | 50 | |
Anthony Léonard | 9bebf1d | 2017-12-21 14:33:51 -0500 | [diff] [blame] | 51 | /** |
Anthony Léonard | 8585cc0 | 2017-12-28 14:03:45 -0500 | [diff] [blame] | 52 | * Method triggered when a panel on the right is closed by user action. It triggers any action needed |
| 53 | * on itself or other view controllers to react properly to this event. |
| 54 | */ |
| 55 | -(void) rightPanelClosed; |
| 56 | |
Anthony Léonard | 0a9904c | 2018-01-11 16:43:47 -0500 | [diff] [blame] | 57 | /** |
| 58 | * Triggered by Conversation view when the current conversation is switching from pending state to |
| 59 | * trusted. It triggers conversation list change in SmartViewVC in order to keep current conversation |
| 60 | * visible in left list (to "follow it"). |
| 61 | */ |
| 62 | -(void) currentConversationTrusted; |
| 63 | |
Anthony Léonard | bee94cc | 2018-01-16 11:42:40 -0500 | [diff] [blame] | 64 | /** |
| 65 | * Triggered by SmartView when list type is changed by user. It closes the right view as the selected conversation |
| 66 | * is not in filtered list anymore. |
| 67 | * @note This method is not to be used if list change is triggered by a left panel view. |
| 68 | */ |
| 69 | -(void) listTypeChanged; |
| 70 | |
Kateryna Kostiuk | e350384 | 2018-12-12 16:39:45 -0500 | [diff] [blame] | 71 | -(void) showConversation:(NSString* )conversationId forAccount:(NSString*)accountId; |
| 72 | -(void) showCall:(NSString* )callId forAccount:(NSString*)accountId forConversation:(NSString*)conversationId; |
| 73 | -(void) showContactRequestFor:(NSString* )accountId contactUri:(NSString*)uri; |
| 74 | |
Alexandre Lision | 5855b6a | 2015-02-03 11:31:05 -0500 | [diff] [blame] | 75 | @end |