Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linphone-desktop
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
linphone-desktop
Commits
f9bebf12
Commit
f9bebf12
authored
Oct 05, 2016
by
Ronan Abhamon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Unstable!!!
parent
06ecb0b2
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
142 additions
and
18 deletions
+142
-18
linphone.pro
tests/linphone.pro
+1
-0
resources.qrc
tests/resources.qrc
+2
-0
Notification.hpp
tests/src/components/notification/Notification.hpp
+1
-1
main.cpp
tests/src/main.cpp
+6
-2
Paned.qml
tests/ui/modules/Linphone/Paned.qml
+86
-0
qmldir
tests/ui/modules/Linphone/qmldir
+3
-0
Calls.qml
tests/ui/views/Calls/Calls.qml
+27
-0
MainWindow.qml
tests/ui/views/MainWindow/MainWindow.qml
+2
-1
NewCall.qml
tests/ui/views/NewCall.qml
+14
-14
No files found.
tests/linphone.pro
View file @
f9bebf12
...
...
@@ -47,6 +47,7 @@ lupdate_only{
ui/modules/Linphone/Styles/Form
/*
.qml \
ui/modules/Linphone/View
/*
.qml \
ui/views
/*
.qml \
ui/views/Calls
/*
.qml \
ui/views/MainWindow
/*
.qml \
}
tests/resources.qrc
View file @
f9bebf12
...
...
@@ -55,6 +55,7 @@
<file>
ui/modules/Linphone/Image/Icon.qml
</file>
<file>
ui/modules/Linphone/InvertedMouseArea.qml
</file>
<file>
ui/modules/Linphone/Menu.qml
</file>
<file>
ui/modules/Linphone/Paned.qml
</file>
<file>
ui/modules/Linphone/Popup/DropDownMenu.qml
</file>
<file>
ui/modules/Linphone/Popup/PopupShadow.qml
</file>
<file>
ui/modules/Linphone/qmldir
</file>
...
...
@@ -84,6 +85,7 @@
<file>
ui/modules/Linphone/View/ScrollableListView.qml
</file>
<file>
ui/scripts/Utils/qmldir
</file>
<file>
ui/scripts/Utils/utils.js
</file>
<file>
ui/views/Calls/Calls.qml
</file>
<file>
ui/views/MainWindow/Contact.qml
</file>
<file>
ui/views/MainWindow/Contacts.qml
</file>
<file>
ui/views/MainWindow/Conversation.qml
</file>
...
...
tests/src/components/notification/Notification.hpp
View file @
f9bebf12
...
...
@@ -6,7 +6,7 @@
// ===================================================================
class
Notification
:
public
QObject
{
Q_OBJECT
Q_OBJECT
;
public:
Notification
(
QObject
*
parent
=
Q_NULLPTR
);
...
...
tests/src/main.cpp
View file @
f9bebf12
...
...
@@ -6,7 +6,7 @@
#include <QQuickView>
#include <QSystemTrayIcon>
#include <QtDebug>
#include <QQmlComponent>
#include "app.hpp"
#include "components/contacts/ContactsListProxyModel.hpp"
#include "components/notification/Notification.hpp"
...
...
@@ -57,8 +57,10 @@ void registerTypes () {
void
addContextProperties
(
QQmlApplicationEngine
&
engine
)
{
QQmlContext
*
context
=
engine
.
rootContext
();
QQmlComponent
component
(
&
engine
,
QUrl
(
"qrc:/ui/views/Calls/Calls.qml"
));
context
->
setContextProperty
(
"Notification"
,
new
Notification
());
context
->
setContextProperty
(
"CallsWindow"
,
component
.
create
());
}
int
main
(
int
argc
,
char
*
argv
[])
{
...
...
@@ -77,8 +79,10 @@ int main (int argc, char *argv[]) {
engine
.
addImportPath
(
":/ui/scripts"
);
engine
.
load
(
QUrl
(
"qrc:/ui/views/MainWindow/MainWindow.qml"
));
if
(
engine
.
rootObjects
().
isEmpty
())
if
(
engine
.
rootObjects
().
isEmpty
())
{
qWarning
()
<<
"Unable to open main window."
;
return
EXIT_FAILURE
;
}
// Enable TrayIconSystem.
if
(
!
QSystemTrayIcon
::
isSystemTrayAvailable
())
...
...
tests/ui/modules/Linphone/Paned.qml
0 → 100644
View file @
f9bebf12
import
QtQuick
2.7
Item
{
id
:
container
property
int
handleLimitLeft
:
0
property
int
handleLimitRight
:
0
property
alias
childA
:
contentA
.
data
property
alias
childB
:
contentB
.
data
onWidthChanged
:
{
console
.
log
(
'
RESIZE
'
,
width
,
handleLimitRight
)
if
(
contentB
.
width
<
handleLimitRight
)
{
console
.
log
(
'
lala
'
,
width
,
handleLimitRight
,
width
-
handle
.
width
-
handleLimitRight
)
contentA
.
width
=
width
-
handle
.
width
-
handleLimitRight
}
else
if
(
contentA
.
width
<
handleLimitLeft
)
{
console
.
log
(
'
zaza
'
,
width
,
handleLimitLeft
)
contentA
.
width
=
handleLimitLeft
}
else
if
(
contentA
.
width
>=
width
-
handleLimitRight
-
20
)
{
console
.
log
(
'
FUCK
'
,
contentA
.
width
,
width
-
handleLimitRight
-
20
)
contentA
.
width
-
handle
.
width
-
handleLimitRight
}
}
Rectangle
{
id
:
contentA
color
:
'
#FFFFFF
'
height
:
parent
.
height
}
MouseArea
{
id
:
handle
property
int
_mouseStart
anchors.left
:
contentA
.
right
cursorShape
:
Qt
.
SplitHCursor
height
:
parent
.
height
hoverEnabled
:
true
width
:
8
onMouseXChanged
:
{
// Necessary because `hoverEnabled` is used.
if
(
!
pressed
)
{
return
}
var
offset
=
mouseX
-
_mouseStart
if
(
container
.
width
-
offset
-
contentA
.
width
-
width
<
handleLimitRight
)
{
contentA
.
width
=
container
.
width
-
width
-
handleLimitRight
}
else
if
(
contentA
.
width
+
offset
<
handleLimitLeft
)
{
contentA
.
width
=
handleLimitLeft
}
else
{
contentA
.
width
=
contentA
.
width
+
offset
}
}
onPressed
:
_mouseStart
=
mouseX
Rectangle
{
anchors.fill
:
parent
color
:
parent
.
pressed
?
'
#5E5E5E
'
:
(
parent
.
containsMouse
?
'
#707070
'
:
'
#C5C5C5
'
)
}
}
Rectangle
{
id
:
contentB
anchors.left
:
handle
.
right
color
:
'
#EAEAEA
'
height
:
parent
.
height
width
:
{
console
.
log
(
'
toto
'
,
container
.
width
,
contentA
.
width
,
container
.
width
-
contentA
.
width
-
handle
.
width
)
return
container
.
width
-
contentA
.
width
-
handle
.
width
}
}
}
tests/ui/modules/Linphone/qmldir
View file @
f9bebf12
...
...
@@ -52,6 +52,9 @@ InvertedMouseArea 1.0 InvertedMouseArea.qml
# Menu
Menu 1.0 Menu.qml
# Paned
Paned 1.0 Paned.qml
# Popup
DropDownMenu 1.0 Popup/DropDownMenu.qml
PopupShadow 1.0 Popup/PopupShadow.qml
...
...
tests/ui/views/Calls/Calls.qml
0 → 100644
View file @
f9bebf12
import
QtQuick
2.7
import
QtQuick
.
Layouts
1.3
import
QtQuick
.
Window
2.2
import
QtQuick
.
Controls
2.0
import
Linphone
1.0
Window
{
minimumHeight
:
480
minimumWidth
:
640
id
:
window
Paned
{
anchors.fill
:
parent
handleLimitLeft
:
parent
.
width
*
0.66
handleLimitRight
:
50
childA
:
Text
{
text
:
'
hello
'
}
childB
:
Text
{
text
:
'
hello2
'
}
}
}
tests/ui/views/MainWindow/MainWindow.qml
View file @
f9bebf12
...
...
@@ -98,7 +98,8 @@ ApplicationWindow {
actions
:
[
ActionButton
{
icon
:
'
call
'
onClicked
:
console
.
log
(
'
clicked
'
)
onClicked
:
CallsWindow
.
show
()
},
ActionButton
{
...
...
tests/ui/views/NewCall.qml
View file @
f9bebf12
...
...
@@ -4,22 +4,22 @@ import QtQuick.Controls 2.0
import
Linphone
1.0
DialogPlus
{
centeredButtons
:
true
minimumHeight
:
300
minimumWidth
:
420
title
:
qsTr
(
'
newCallTitle
'
)
centeredButtons
:
true
minimumHeight
:
300
minimumWidth
:
420
title
:
qsTr
(
'
newCallTitle
'
)
buttons
:
TextButtonA
{
text
:
qsTr
(
'
cancel
'
)
}
buttons
:
TextButtonA
{
text
:
qsTr
(
'
cancel
'
)
}
Item
{
anchors.fill
:
parent
anchors.leftMargin
:
25
anchors.rightMargin
:
25
Item
{
anchors.fill
:
parent
anchors.leftMargin
:
25
anchors.rightMargin
:
25
SelectContact
{
anchors.fill
:
parent
}
SelectContact
{
anchors.fill
:
parent
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment