IMTableCellView.h 2.44 KB
Newer Older
1
/*
Sébastien Blin's avatar
Sébastien Blin committed
2
 *  Copyright (C) 2016-2019 Savoir-faire Linux Inc.
3
 *  Author: Alexandre Lision <alexandre.lision@savoirfairelinux.com>
4
 *  Author: Anthony Léonard <anthony.leonard@savoirfairelinux.com>
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 3 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA.
 */

#import <Cocoa/Cocoa.h>
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
22
#import "MessageBubbleView.h"
23 24 25 26 27

@interface IMTableCellView : NSTableCellView

@property (nonatomic, strong) IBOutlet NSImageView* photoView;
@property (nonatomic, strong) IBOutlet NSTextView* msgView;
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
28
@property (nonatomic, strong) IBOutlet MessageBubbleView* msgBackground;
29 30 31 32
@property (nonatomic, strong) IBOutlet NSButton* acceptButton;
@property (nonatomic, strong) IBOutlet NSButton* declineButton;
@property (nonatomic, strong) IBOutlet NSProgressIndicator* progressIndicator;
@property (nonatomic, strong) IBOutlet NSTextField* statusLabel;
33 34
@property (nonatomic, strong) IBOutlet NSBox* timeBox;
@property (nonatomic, strong) IBOutlet NSTextField* timeLabel;
35
@property (nonatomic, strong) IBOutlet NSButton* transferedFileName;
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
36
@property (nonatomic, strong) IBOutlet NSImageView* transferedImage;
37
@property (nonatomic, strong) IBOutlet NSProgressIndicator* sendingMessageIndicator;
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
38
@property (nonatomic, strong) IBOutlet NSImageView* messageFailed;
39
@property (nonatomic, strong) IBOutlet NSView* messageStatus;
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
40
@property (nonatomic, strong) IBOutlet NSButton* openImagebutton;
41

42 43

- (uint64_t) interaction;
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
44
- (void) setupForInteraction:(uint64_t)inter isFailed:(bool) failed;
45
- (void) setupForInteraction:(uint64_t)inter;
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
46
- (void) updateMessageConstraint:(CGFloat) width andHeight: (CGFloat) height timeIsVisible: (bool) visible isTopPadding: (bool) padding;
47
- (void) updateImageConstraint: (CGFloat) width andHeight: (CGFloat) height;
Kateryna Kostiuk's avatar
Kateryna Kostiuk committed
48
- (void) updateImageConstraintWithMax: (CGFloat) maxDimension;
49
- (void) invalidateImageConstraints;
50 51

@end