Alexandre Lision | 4dfcafc | 2015-08-20 12:43:23 -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 | 4dfcafc | 2015-08-20 12:43:23 -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. |
| 18 | */ |
| 19 | |
| 20 | #import <Cocoa/Cocoa.h> |
Kateryna Kostiuk | 6615098 | 2020-09-18 15:14:36 -0400 | [diff] [blame] | 21 | #include <qstring.h> |
Alexandre Lision | 4dfcafc | 2015-08-20 12:43:23 -0400 | [diff] [blame] | 22 | |
Olivier Soldano | d431155 | 2017-11-20 15:09:53 -0500 | [diff] [blame] | 23 | namespace lrc { |
| 24 | namespace api { |
| 25 | class ConversationModel; |
Anthony Léonard | 9bebf1d | 2017-12-21 14:33:51 -0500 | [diff] [blame] | 26 | |
| 27 | namespace conversation { |
| 28 | struct Info; |
| 29 | } |
Olivier Soldano | d431155 | 2017-11-20 15:09:53 -0500 | [diff] [blame] | 30 | } |
| 31 | } |
| 32 | |
Alexandre Lision | bf0385e | 2015-10-22 17:36:28 -0400 | [diff] [blame] | 33 | @interface SmartViewVC : NSViewController <NSTextFieldDelegate> |
Alexandre Lision | 4dfcafc | 2015-08-20 12:43:23 -0400 | [diff] [blame] | 34 | |
Kateryna Kostiuk | 882cbac | 2017-07-05 17:29:00 -0400 | [diff] [blame] | 35 | @property (unsafe_unretained) IBOutlet NSTabView* tabbar; |
| 36 | |
Anthony Léonard | 9bebf1d | 2017-12-21 14:33:51 -0500 | [diff] [blame] | 37 | - (BOOL)setConversationModel:(lrc::api::ConversationModel *)conversationModel; |
Olivier Soldano | d431155 | 2017-11-20 15:09:53 -0500 | [diff] [blame] | 38 | |
Kateryna Kostiuk | 882cbac | 2017-07-05 17:29:00 -0400 | [diff] [blame] | 39 | - (void)startCallForRow:(id)sender; |
| 40 | |
Anthony Léonard | 9bebf1d | 2017-12-21 14:33:51 -0500 | [diff] [blame] | 41 | /** |
| 42 | * This method is meant to be used by RingWindowController to set selected conversation in case |
| 43 | * a selection is triggered not by user but by LRC signal. If conversation is already selected, this method |
| 44 | * returns immediatly without changing any state. |
| 45 | * @param conv selected conversation |
| 46 | * @param model model responsible for conversation |
| 47 | */ |
| 48 | -(void)selectConversation:(const lrc::api::conversation::Info&)conv model:(lrc::api::ConversationModel*)model; |
| 49 | |
Anthony Léonard | 8585cc0 | 2017-12-28 14:03:45 -0500 | [diff] [blame] | 50 | /** |
| 51 | * Deselect any selected conversation |
| 52 | */ |
| 53 | -(void)deselect; |
| 54 | |
Anthony Léonard | 0a9904c | 2018-01-11 16:43:47 -0500 | [diff] [blame] | 55 | /** |
| 56 | * Change list selection to Conversation |
| 57 | */ |
| 58 | -(void)selectConversationList; |
| 59 | |
Anthony Léonard | d00cd18 | 2018-01-17 09:21:27 -0500 | [diff] [blame] | 60 | /** |
| 61 | * Change list selection to Pending |
| 62 | */ |
| 63 | -(void)selectPendingList; |
Kateryna Kostiuk | ab499f4 | 2018-04-16 12:27:33 -0400 | [diff] [blame] | 64 | /** |
| 65 | * clear conversation when account list is empty |
| 66 | */ |
| 67 | -(void) clearConversationModel; |
Anthony Léonard | d00cd18 | 2018-01-17 09:21:27 -0500 | [diff] [blame] | 68 | |
Kateryna Kostiuk | 133364b | 2018-10-31 11:36:08 -0400 | [diff] [blame] | 69 | -(void) reloadConversationWithUid:(NSString *)uid; |
Kateryna Kostiuk | 4db6109 | 2019-10-17 16:57:40 -0400 | [diff] [blame] | 70 | -(void) reloadConversationWithURI:(NSString *)uri; |
Kateryna Kostiuk | 6615098 | 2020-09-18 15:14:36 -0400 | [diff] [blame] | 71 | -(QString)getSelectedUID; |
Kateryna Kostiuk | 133364b | 2018-10-31 11:36:08 -0400 | [diff] [blame] | 72 | |
Alexandre Lision | 4dfcafc | 2015-08-20 12:43:23 -0400 | [diff] [blame] | 73 | @end |