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

fix: tab bar

Present help info from any window

Change-Id: I5508a323137a16284cc96b011e11eddcf96e05bb
parent 29311508
Branches
No related tags found
No related merge requests found
...@@ -254,6 +254,8 @@ SET(ringclient_OTHERS ...@@ -254,6 +254,8 @@ SET(ringclient_OTHERS
src/NSString+Extensions.mm src/NSString+Extensions.mm
src/RingMainWindow.h src/RingMainWindow.h
src/RingMainWindow.mm src/RingMainWindow.mm
src/MenuResponder.h
src/MenuResponder.mm
src/Shader.metal src/Shader.metal
) )
......
/*
* Copyright (C) 2020 Savoir-faire Linux Inc.
* Author: Kateryna Kostiuk <kateryna.kostiuk@savoirfairelinux.com>
*
* 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>
NS_ASSUME_NONNULL_BEGIN
@interface MenuResponder : NSResponder
@end
NS_ASSUME_NONNULL_END
/*
* Copyright (C) 2020 Savoir-faire Linux Inc.
* Author: Kateryna Kostiuk <kateryna.kostiuk@savoirfairelinux.com>
*
* 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 "MenuResponder.h"
@implementation MenuResponder
- (IBAction)showHelp:(id)sender
{
NSURL * helpFile = [NSURL URLWithString: @"https://jami.net/help/"];
[[NSWorkspace sharedWorkspace] openURL:helpFile];
}
@end
...@@ -631,10 +631,4 @@ typedef NS_ENUM(NSInteger, ViewState) { ...@@ -631,10 +631,4 @@ typedef NS_ENUM(NSInteger, ViewState) {
[self changeViewTo:SHOW_CONVERSATION_SCREEN]; [self changeViewTo:SHOW_CONVERSATION_SCREEN];
} }
- (void)showHelp:(id)sender
{
NSURL * helpFile = [NSURL URLWithString: @"https://jami.net/help/"];
[[NSWorkspace sharedWorkspace] openURL:helpFile];
}
@end @end
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14460.31" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES"> <document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="15705" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
<dependencies> <dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14460.31"/> <plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="15705"/>
</dependencies> </dependencies>
<objects> <objects>
<customObject id="-2" userLabel="File's Owner" customClass="RingWindowController"> <customObject id="-2" userLabel="File's Owner" customClass="RingWindowController">
...@@ -326,16 +326,18 @@ ...@@ -326,16 +326,18 @@
<items> <items>
<menuItem title="Jami Help" keyEquivalent="?" id="492"> <menuItem title="Jami Help" keyEquivalent="?" id="492">
<connections> <connections>
<action selector="showHelp:" target="-1" id="493"/> <action selector="showHelp:" target="TCU-co-tEb" id="gTr-qt-aGe"/>
</connections> </connections>
</menuItem> </menuItem>
</items> </items>
</menu> </menu>
</menuItem> </menuItem>
</items> </items>
<point key="canvasLocation" x="139" y="154"/>
</menu> </menu>
<customObject id="494" customClass="AppDelegate"/> <customObject id="494" customClass="AppDelegate"/>
<customObject id="420" customClass="NSFontManager"/> <customObject id="420" customClass="NSFontManager"/>
<customObject id="592" customClass="SUUpdater"/> <customObject id="592" customClass="SUUpdater"/>
<customObject id="TCU-co-tEb" customClass="MenuResponder"/>
</objects> </objects>
</document> </document>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment