Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
J
jami-client-uwp
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
savoirfairelinux
jami-client-uwp
Commits
1ba34442
Commit
1ba34442
authored
8 years ago
by
Nicolas Jager
Browse files
Options
Downloads
Patches
Plain Diff
fix : wizzard create account with good credentials
Change-Id: Ie64dd640cea11876575e3e9fad4d0e4f88973818 Tuleap: #1283
parent
e46fd0d9
No related branches found
No related tags found
No related merge requests found
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
RingD.cpp
+9
-7
9 additions, 7 deletions
RingD.cpp
RingD.h
+1
-4
1 addition, 4 deletions
RingD.h
Wizard.xaml
+7
-2
7 additions, 2 deletions
Wizard.xaml
Wizard.xaml.cpp
+15
-7
15 additions, 7 deletions
Wizard.xaml.cpp
Wizard.xaml.h
+1
-0
1 addition, 0 deletions
Wizard.xaml.h
with
33 additions
and
20 deletions
RingD.cpp
+
9
−
7
View file @
1ba34442
...
@@ -354,6 +354,13 @@ void RingClientUWP::RingD::deleteAccount(String ^ accountId)
...
@@ -354,6 +354,13 @@ void RingClientUWP::RingD::deleteAccount(String ^ accountId)
tasksList_
.
push
(
task
);
tasksList_
.
push
(
task
);
}
}
void
RingClientUWP
::
RingD
::
registerThisDevice
(
String
^
pin
,
String
^
archivePassword
)
{
tasksList_
.
push
(
ref
new
RingD
::
Task
(
Request
::
RegisterDevice
,
pin
,
archivePassword
));
archivePassword
=
""
;
pin
=
""
;
}
void
void
RingClientUWP
::
RingD
::
startDaemon
()
RingClientUWP
::
RingD
::
startDaemon
()
{
{
...
@@ -649,13 +656,8 @@ RingClientUWP::RingD::startDaemon()
...
@@ -649,13 +656,8 @@ RingClientUWP::RingD::startDaemon()
else
{
else
{
switch
(
_startingStatus
)
{
switch
(
_startingStatus
)
{
case
StartingStatus
::
REGISTERING_ON_THIS_PC
:
case
StartingStatus
::
REGISTERING_ON_THIS_PC
:
{
tasksList_
.
push
(
ref
new
RingD
::
Task
(
Request
::
AddRingAccount
));
break
;
}
case
StartingStatus
::
REGISTERING_THIS_DEVICE
:
case
StartingStatus
::
REGISTERING_THIS_DEVICE
:
{
{
tasksList_
.
push
(
ref
new
RingD
::
Task
(
Request
::
RegisterDevice
,
_pin
,
_password
));
break
;
break
;
}
}
case
StartingStatus
::
NORMAL
:
case
StartingStatus
::
NORMAL
:
...
@@ -771,8 +773,8 @@ RingD::dequeueTasks()
...
@@ -771,8 +773,8 @@ RingD::dequeueTasks()
break
;
break
;
case
Request
::
RegisterDevice
:
case
Request
::
RegisterDevice
:
{
{
auto
pin
=
Utils
::
toString
(
_pin
);
auto
pin
=
Utils
::
toString
(
task
->
_pin
);
auto
password
=
Utils
::
toString
(
_password
);
auto
password
=
Utils
::
toString
(
task
->
_password
);
std
::
map
<
std
::
string
,
std
::
string
>
deviceDetails
;
std
::
map
<
std
::
string
,
std
::
string
>
deviceDetails
;
deviceDetails
.
insert
(
std
::
make_pair
(
DRing
::
Account
::
ConfProperties
::
TYPE
,
"RING"
));
deviceDetails
.
insert
(
std
::
make_pair
(
DRing
::
Account
::
ConfProperties
::
TYPE
,
"RING"
));
...
...
This diff is collapsed.
Click to expand it.
RingD.h
+
1
−
4
View file @
1ba34442
...
@@ -61,8 +61,6 @@ public:
...
@@ -61,8 +61,6 @@ public:
}
}
}
}
property
StartingStatus
_startingStatus
;
property
StartingStatus
_startingStatus
;
property
String
^
_pin
;
// you should RM ME
property
String
^
_password
;
// refatco : think a little... RM ME
void
cancelOutGoingCall2
(
String
^
callId
);
// marche
void
cancelOutGoingCall2
(
String
^
callId
);
// marche
...
@@ -100,10 +98,9 @@ internal:
...
@@ -100,10 +98,9 @@ internal:
void
eraseCacheFolder
();
void
eraseCacheFolder
();
void
updateAccount
(
String
^
accountId
);
void
updateAccount
(
String
^
accountId
);
void
deleteAccount
(
String
^
accountId
);
void
deleteAccount
(
String
^
accountId
);
void
registerThisDevice
(
String
^
pin
,
String
^
archivePassword
);
/* TODO : move members */
/* TODO : move members */
///bool hasConfig; // replaced by startingStatus
std
::
string
accountName
;
// YOU SHOULD RM ME
String
^
currentCallId
;
// to save ongoing call id during visibility change
String
^
currentCallId
;
// to save ongoing call id during visibility change
/* events */
/* events */
...
...
This diff is collapsed.
Click to expand it.
Wizard.xaml
+
7
−
2
View file @
1ba34442
...
@@ -54,9 +54,13 @@
...
@@ -54,9 +54,13 @@
<TextBox x:Name="_aliasTextBox_"
<TextBox x:Name="_aliasTextBox_"
Margin="10"
Margin="10"
PlaceholderText="Enter your username"/>
PlaceholderText="Enter your username"/>
<PasswordBox Margin="10"
<PasswordBox x:Name="_password_"
Margin="10"
PasswordChanged="validatePassword"
PlaceholderText="Enter your password"/>
PlaceholderText="Enter your password"/>
<PasswordBox Margin="10,10,10,20"
<PasswordBox x:Name="_passwordCheck_"
Margin="10,10,10,20"
PasswordChanged="validatePassword"
PlaceholderText="Repeat your Password"/>
PlaceholderText="Repeat your Password"/>
</StackPanel>
</StackPanel>
<!-- SIP account. -->
<!-- SIP account. -->
...
@@ -81,6 +85,7 @@
...
@@ -81,6 +85,7 @@
VerticalAlignment="Center"
VerticalAlignment="Center"
HorizontalAlignment="Center"
HorizontalAlignment="Center"
Content=""
Content=""
IsEnabled="False"
Click="_createAccountYes__Click"
Click="_createAccountYes__Click"
Style="{StaticResource ButtonStyle2}"/>
Style="{StaticResource ButtonStyle2}"/>
</StackPanel>
</StackPanel>
...
...
This diff is collapsed.
Click to expand it.
Wizard.xaml.cpp
+
15
−
7
View file @
1ba34442
...
@@ -32,14 +32,12 @@ void
...
@@ -32,14 +32,12 @@ void
Wizard
::
_createAccountYes__Click
(
Object
^
sender
,
RoutedEventArgs
^
e
)
Wizard
::
_createAccountYes__Click
(
Object
^
sender
,
RoutedEventArgs
^
e
)
{
{
auto
alias
=
_aliasTextBox_
->
Text
;
auto
alias
=
_aliasTextBox_
->
Text
;
if
(
alias
->
IsEmpty
())
alias
=
"windows user"
;
std
::
wstring
wstr
(
alias
->
Begin
());
std
::
string
str
(
wstr
.
begin
(),
wstr
.
end
());
RingD
::
instance
->
_startingStatus
=
StartingStatus
::
REGISTERING_ON_THIS_PC
;
RingD
::
instance
->
_startingStatus
=
StartingStatus
::
REGISTERING_ON_THIS_PC
;
RingD
::
instance
->
accountName
=
std
::
string
(
wstr
.
begin
(),
wstr
.
end
());
this
->
Dispatcher
->
RunAsync
(
Windows
::
UI
::
Core
::
CoreDispatcherPriority
::
High
,
ref
new
Windows
::
UI
::
Core
::
DispatchedHandler
([
this
]
()
{
this
->
Dispatcher
->
RunAsync
(
Windows
::
UI
::
Core
::
CoreDispatcherPriority
::
High
,
ref
new
Windows
::
UI
::
Core
::
DispatchedHandler
([
this
]
()
{
this
->
Frame
->
Navigate
(
Windows
::
UI
::
Xaml
::
Interop
::
TypeName
(
RingClientUWP
::
MainPage
::
typeid
));
this
->
Frame
->
Navigate
(
Windows
::
UI
::
Xaml
::
Interop
::
TypeName
(
RingClientUWP
::
MainPage
::
typeid
));
RingD
::
instance
->
createRINGAccount
(
_aliasTextBox_
->
Text
,
_password_
->
Password
,
true
);
_password_
->
Password
=
""
;
}));
}));
}
}
...
@@ -118,11 +116,21 @@ Wizard::_avatarWebcamCaptureBtn__Click(Platform::Object^ sender, Windows::UI::Xa
...
@@ -118,11 +116,21 @@ Wizard::_avatarWebcamCaptureBtn__Click(Platform::Object^ sender, Windows::UI::Xa
void
RingClientUWP
::
Views
::
Wizard
::
_addAccountYes__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
)
void
RingClientUWP
::
Views
::
Wizard
::
_addAccountYes__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
)
{
{
RingD
::
instance
->
_pin
=
_PINTextBox_
->
Text
;
RingD
::
instance
->
_password
=
_ArchivePassword_
->
Password
;
RingD
::
instance
->
_startingStatus
=
StartingStatus
::
REGISTERING_THIS_DEVICE
;
RingD
::
instance
->
_startingStatus
=
StartingStatus
::
REGISTERING_THIS_DEVICE
;
this
->
Dispatcher
->
RunAsync
(
Windows
::
UI
::
Core
::
CoreDispatcherPriority
::
Normal
,
ref
new
Windows
::
UI
::
Core
::
DispatchedHandler
([
this
]()
{
this
->
Dispatcher
->
RunAsync
(
Windows
::
UI
::
Core
::
CoreDispatcherPriority
::
Normal
,
ref
new
Windows
::
UI
::
Core
::
DispatchedHandler
([
this
]()
{
this
->
Frame
->
Navigate
(
Windows
::
UI
::
Xaml
::
Interop
::
TypeName
(
RingClientUWP
::
MainPage
::
typeid
));
this
->
Frame
->
Navigate
(
Windows
::
UI
::
Xaml
::
Interop
::
TypeName
(
RingClientUWP
::
MainPage
::
typeid
));
RingD
::
instance
->
registerThisDevice
(
_PINTextBox_
->
Text
,
_ArchivePassword_
->
Password
);
_ArchivePassword_
->
Password
=
""
;
_PINTextBox_
->
Text
=
""
;
}));
}));
}
}
void
RingClientUWP
::
Views
::
Wizard
::
validatePassword
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
)
{
_createAccountYes_
->
IsEnabled
=
(
_password_
->
Password
==
_passwordCheck_
->
Password
&&
_password_
->
Password
->
Length
()
>
0
)
?
true
:
false
;
}
This diff is collapsed.
Click to expand it.
Wizard.xaml.h
+
1
−
0
View file @
1ba34442
...
@@ -17,6 +17,7 @@ private:
...
@@ -17,6 +17,7 @@ private:
void
_showAddAccountMenuBtn__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
);
void
_showAddAccountMenuBtn__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
);
void
_avatarWebcamCaptureBtn__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
);
void
_avatarWebcamCaptureBtn__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
);
void
_addAccountYes__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
);
void
_addAccountYes__Click
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
);
void
validatePassword
(
Platform
::
Object
^
sender
,
Windows
::
UI
::
Xaml
::
RoutedEventArgs
^
e
);
};
};
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment