Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
chat
fairchat
Commits
a892ba7c
Commit
a892ba7c
authored
Mar 08, 2018
by
armin
Browse files
Merge branch 'master' into 'production'
Master See merge request
!39
parents
b3045f7c
67c3b7af
Pipeline
#65
passed with stage
in 2 minutes and 43 seconds
Changes
83
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
0 → 100644
View file @
a892ba7c
image
:
docker:stable
variables
:
GIT_SUBMODULE_STRATEGY
:
recursive
stages
:
-
build
docker:build:Qt:5.9:
image
:
afelder/qt-android-docker
stage
:
build
script
:
-
mkdir build
-
cd build
-
/opt/Qt/5.9.3/android_armv7/bin/qmake -spec android-g++ ../RocketChatMobileModular.pro
-
make -j9
-
make install INSTALL_ROOT=$(pwd)/android-build
-
/opt/Qt/5.9.3/android_armv7/bin/androiddeployqt --input fairchat/android-libfairchat.so-deployment-settings.json --output android-build --deployment bundled --android-platform android-25 --jdk /usr/lib/jvm/java-8-oracle --gradle
artifacts
:
name
:
"
$CI_COMMIT_REF_NAME"
paths
:
-
build/android-build/build/outputs/apk/android-build-debug.apk
expire_in
:
6 week
\ No newline at end of file
README.md
View file @
a892ba7c
[

](https://git.fairkom.net/chat/fairchat/commits/master)
## fairchat App
Qt based mobile app for Android, iOS, Windows Phone.
...
...
engine
@
d2b3560e
Compare
fbe3688f
...
d2b3560e
Subproject commit
fbe3688fafa48684390480209d112529d4c02787
Subproject commit
d2b3560e036b302dc71403bb4386f327575ff8fc
fairchat/android/build.gradle
View file @
a892ba7c
...
...
@@ -27,6 +27,8 @@ buildscript {
repositories
{
jcenter
()
maven
{
url
'https://maven.fabric.io/public'
}
maven
{
url
'https://maven.google.com'
}
}
dependencies
{
...
...
@@ -41,6 +43,8 @@ allprojects {
jcenter
()
mavenCentral
()
maven
{
url
'https://maven.fabric.io/public'
}
maven
{
url
'https://maven.google.com'
}
}
}
...
...
@@ -48,6 +52,8 @@ apply plugin: 'com.android.application'
repositories
{
maven
{
url
'https://maven.fabric.io/public'
}
maven
{
url
'https://maven.google.com'
}
}
apply
plugin:
'io.fabric'
...
...
@@ -60,17 +66,17 @@ crashlytics {
dependencies
{
compile
fileTree
(
dir:
'libs'
,
include:
[
'*.jar'
])
compile
(
'com.crashlytics.sdk.android:crashlytics:2.
7
.1@aar'
)
{
compile
(
'com.crashlytics.sdk.android:crashlytics:2.
9
.1@aar'
)
{
transitive
=
true
}
compile
(
'com.crashlytics.sdk.android:crashlytics-ndk:
1.1.6
@aar'
)
{
compile
(
'com.crashlytics.sdk.android:crashlytics-ndk:
2.0.1
@aar'
)
{
transitive
=
true
}
compile
'com.android.support:appcompat-v7:25.3.1'
compile
'com.google.android.gms:play-services-gcm:1
0.2.4
'
compile
'com.google.firebase:firebase-core:1
0.2.4
'
compile
'com.google.firebase:firebase-crash:1
0.2.4
'
compile
'com.google.firebase:firebase-messaging:1
0.2.4
'
compile
'com.google.android.gms:play-services-gcm:1
1.8.0
'
compile
'com.google.firebase:firebase-core:1
1.8.0
'
compile
'com.google.firebase:firebase-crash:1
1.8.0
'
compile
'com.google.firebase:firebase-messaging:1
1.8.0
'
compile
'com.android.support:multidex:1.0.1'
compile
'me.leolin:ShortcutBadger:1.1.19@aar'
...
...
@@ -129,7 +135,7 @@ android {
apply
plugin:
'com.google.gms.google-services'
copy
{
from
'build/intermediates/exploded-aar/com.crashlytics.sdk.android/crashlytics-ndk/
1.1.6
/jni/'
from
'build/intermediates/exploded-aar/com.crashlytics.sdk.android/crashlytics-ndk/
2.0.1
/jni/'
into
'libs'
include
'**/*'
}
...
...
fairchat/config.h
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
#ifndef CONFIG1_H
#define CONFIG1_H
...
...
fairchat/fairchat.pro
View file @
a892ba7c
...
...
@@ -25,7 +25,7 @@ else:unix: PRE_TARGETDEPS += $$OUT_PWD/../engine/libengine.a
TARGET
=
fairchat
VER_MAJ
=
1
VER_MIN
=
1
VER_PAT
=
3
VER_PAT
=
4
VERSION
=
$$
sprintf
(
"%1.%2.%3"
,
$$
VER_MAJ
,
$$
VER_MIN
,
$$
VER_PAT
)
DEFINES
+=
VERSION
=
\\\
"$$VERSION\\\"
...
...
fairchat/ios/src/FileHandlerActivity.h
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
fairchat/ios/src/IosBadges.h
View file @
a892ba7c
//
// IosBadges.h
// ucom
//
// Created by armin on 26/06/2017.
//
//
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
#ifndef IosBadges_h
#define IosBadges_h
class
IosBadges
{
public:
IosBadges
()
=
delete
;
~
IosBadges
()
=
delete
;
static
void
setBadges
(
int
number
);
class
IosBadges
{
public:
IosBadges
()
=
delete
;
~
IosBadges
()
=
delete
;
static
void
setBadges
(
int
number
);
};
...
...
fairchat/ios/src/IosGalleryPicker.h
View file @
a892ba7c
//
// IosGalleryPicker.h
// ucom
//
// Created by armin on 08/03/17.
//
//
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
#ifndef IosGalleryPicker_h
#define IosGalleryPicker_h
...
...
@@ -12,27 +25,28 @@
#include <QObject>
#include <QString>
class
IosGalleryPicker
:
public
QObject
class
IosGalleryPicker
:
public
QObject
{
Q_OBJECT
public:
explicit
IosGalleryPicker
();
QString
imagePath
(){
return
mImagePath
;
}
void
open
();
void
receiveFile
(
QString
pFileUrl
);
private:
QString
mImagePath
;
void
*
mDelegate
;
signals:
void
filePicked
(
QString
fileUrl
);
Q_OBJECT
public:
explicit
IosGalleryPicker
();
QString
imagePath
()
{
return
mImagePath
;
}
void
open
();
void
receiveFile
(
QString
pFileUrl
);
private:
QString
mImagePath
;
void
*
mDelegate
;
signals:
void
filePicked
(
QString
fileUrl
);
};
#endif
/* IosGalleryPicker_h */
fairchat/ios/src/fileopener.h
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
#ifndef FILEOPENER_H
#define FILEOPENER_H
...
...
@@ -5,11 +26,11 @@
class
FileOpener
:
public
QObject
{
Q_OBJECT
public:
static
void
callFileOpenDialog
(
QString
path
);
private:
explicit
FileOpener
(
QObject
*
parent
=
0
);
Q_OBJECT
public:
static
void
callFileOpenDialog
(
QString
path
);
private:
explicit
FileOpener
(
QObject
*
parent
=
0
);
};
...
...
fairchat/ios/src/ioshelper.cpp
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
#include "ioshelper.h"
IosHelper
::
IosHelper
(
QObject
*
parent
)
:
QObject
(
parent
)
IosHelper
::
IosHelper
(
QObject
*
parent
)
:
QObject
(
parent
)
{
mShareHelper
=
ShareHelperSingelton
::
getInstance
();
mGalleryPicker
=
new
IosGalleryPicker
();
...
...
@@ -26,12 +47,13 @@ void IosHelper::checkForpendingNotification()
void
IosHelper
::
checkForFileLink
()
{
QString
path
=
mShareHelper
->
getPath
();
if
(
!
path
.
isEmpty
()){
emit
shareLinkReceived
(
path
);
if
(
!
path
.
isEmpty
()
)
{
emit
shareLinkReceived
(
path
);
}
}
void
IosHelper
::
openFileDialog
(
QString
pPath
)
void
IosHelper
::
openFileDialog
(
QString
pPath
)
{
FileOpener
::
callFileOpenDialog
(
pPath
);
}
...
...
@@ -46,7 +68,7 @@ void IosHelper::registerForPush()
mNotificationsObject
.
registerWithService
();
}
void
IosHelper
::
setBadgeNumber
(
int
pNumber
)
void
IosHelper
::
setBadgeNumber
(
int
pNumber
)
{
IosBadges
::
setBadges
(
pNumber
);
}
fairchat/ios/src/ioshelper.h
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
#ifndef IOSHELPER_H
#define IOSHELPER_H
...
...
@@ -14,28 +35,28 @@
class
IosHelper
:
public
QObject
{
Q_OBJECT
public:
explicit
IosHelper
(
QObject
*
parent
=
nullptr
);
~
IosHelper
();
protected:
IosGalleryPicker
*
mGalleryPicker
=
nullptr
;
ShareHelperSingelton
*
mShareHelper
=
nullptr
;
Notifications
mNotificationsObject
;
signals:
void
filePicked
(
QString
pFile
);
void
shareLinkReceived
(
QString
pLink
);
void
pushTokenReceived
(
QString
pToken
);
void
pushMessageReceived
(
QString
pServer
,
QString
pRid
,
QString
pName
,
QString
pType
);
public
slots
:
void
checkForpendingNotification
();
void
checkForFileLink
();
void
openFileDialog
(
QString
pPath
);
void
openGalleryPicker
();
void
registerForPush
();
void
setBadgeNumber
(
int
pNumber
);
Q_OBJECT
public:
explicit
IosHelper
(
QObject
*
parent
=
nullptr
);
~
IosHelper
();
protected:
IosGalleryPicker
*
mGalleryPicker
=
nullptr
;
ShareHelperSingelton
*
mShareHelper
=
nullptr
;
Notifications
mNotificationsObject
;
signals:
void
filePicked
(
QString
pFile
);
void
shareLinkReceived
(
QString
pLink
);
void
pushTokenReceived
(
QString
pToken
);
void
pushMessageReceived
(
QString
pServer
,
QString
pRid
,
QString
pName
,
QString
pType
);
public
slots
:
void
checkForpendingNotification
();
void
checkForFileLink
();
void
openFileDialog
(
QString
pPath
);
void
openGalleryPicker
();
void
registerForPush
();
void
setBadgeNumber
(
int
pNumber
);
};
#endif // IOSHELPER_H
fairchat/ios/src/shareheplersingelton.h
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
#ifndef SHAREHEPLERSINGELTON_H
#define SHAREHEPLERSINGELTON_H
#include <QObject>
#include <QString>
class
ShareHelperSingelton
:
public
QObject
{
Q_OBJECT
class
ShareHelperSingelton
:
public
QObject
{
Q_OBJECT
public:
static
ShareHelperSingelton
*
getInstance
();
public:
static
ShareHelperSingelton
*
getInstance
();
ShareHelperSingelton
&
operator
=
(
ShareHelperSingelton
const
&
)
=
delete
;
ShareHelperSingelton
(
ShareHelperSingelton
const
&
)
=
delete
;
ShareHelperSingelton
&
operator
=
(
ShareHelperSingelton
const
&
)
=
delete
;
ShareHelperSingelton
(
ShareHelperSingelton
const
&
)
=
delete
;
QString
getPath
();
void
setPath
(
QString
pPath
);
QString
getPath
();
void
setPath
(
QString
pPath
);
private:
ShareHelperSingelton
(){}
static
ShareHelperSingelton
*
mInstance
;
QString
mCurPath
;
private:
ShareHelperSingelton
()
{}
static
ShareHelperSingelton
*
mInstance
;
QString
mCurPath
;
signals:
void
shareLinkReceived
(
QString
link
);
signals:
void
shareLinkReceived
(
QString
link
);
};
...
...
fairchat/javascript/channelSort.js
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
WorkerScript
.
onMessage
=
function
(
msgObj
)
{
var
model
=
msgObj
.
model
var
order
=
msgObj
.
order
...
...
fairchat/javascript/emoji.js
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
function
createEmojButton
(
text
,
image
,
model
,
custom
){
var
object
=
{
"
custom
"
:
custom
,
"
emojiText
"
:
text
,
"
image
"
:
image
,
"
customFromDDP
"
:
false
,
"
emojiDownloadName
"
:
""
};
...
...
fairchat/javascript/linkhelper.js
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
function
openFileExternally
(
file
)
{
console
.
log
(
Qt
.
platform
)
...
...
fairchat/javascript/messageURLParser.js
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *
* *
* RocketChatMobileEngine 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. *
* *
* RocketChatMobileEngine 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 RocketChatMobileEngine. If not, see <http://www.gnu.org/licenses/>. *
* *
********************************************************************************************/
fairchat/javascript/messagesFunctions.js
View file @
a892ba7c
/********************************************************************************************
* *
* Copyright (C) 2017 Armin Felder, Dennis Beier *
* This file is part of RocketChatMobileEngine <https://git.fairkom.net/chat/fairchat>. *