SmartPanel.xaml 64.7 KB
Newer Older
Nicolas Jager's avatar
Nicolas Jager committed
1 2 3
<!-- **********************************************************************
* Copyright (C) 2016 by Savoir-faire Linux                                *
* Author: Jäger Nicolas<nicolas.jager@savoirfairelinux.com>               *
4
* Author: Traczyk Andreas<andreas.traczyk@savoirfairelinux.com>           *
Nicolas Jager's avatar
Nicolas Jager committed
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
*                                                                         *
* 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, see <http://www.gnu.org/licenses/> .  *
*********************************************************************** -->
<Page x:Class="RingClientUWP.Views.SmartPanel"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:local="using:RingClientUWP"
23
      xmlns:controls="using:RingClientUWP.Controls"
Nicolas Jager's avatar
Nicolas Jager committed
24
      xmlns:views="using:RingClientUWP.Views"
Nicolas Jager's avatar
Nicolas Jager committed
25 26
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
27
      NavigationCacheMode="Enabled"
Nicolas Jager's avatar
Nicolas Jager committed
28 29
      mc:Ignorable="d">

Nicolas Jager's avatar
Nicolas Jager committed
30
    <Page.Resources>
Nicolas Jager's avatar
Nicolas Jager committed
31 32 33 34 35
        <!-- converters -->
        <views:NewMessageBubleNotification x:Key="_NewMessageBubleNotification_" />
        <views:IncomingVisibility x:Key="_IncomingVisibility_" />
        <views:OutGoingVisibility x:Key="_OutGoingVisibility_" />
        <views:HasAnActiveCall x:Key="_HasAnActiveCall_" />
36 37
        <views:AccountTypeToSourceImage x:Key="_AccountTypeToSourceImage_" />
        <views:AccountSelectedToVisibility x:Key="_AccountSelectedToVisibility_" />
38
        <views:CollapseEmptyString x:Key="_CollapseEmptyString_" />
Nicolas Jager's avatar
Nicolas Jager committed
39

Nicolas Jager's avatar
Nicolas Jager committed
40 41 42 43
        <!-- template for contacts. -->
        <DataTemplate x:Key="ContactTemplate"
                      x:DataType="local:Contact">
            <Grid>
44 45 46
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="310"/>
                </Grid.ColumnDefinitions>
Nicolas Jager's avatar
Nicolas Jager committed
47 48 49 50
                <Grid.RowDefinitions>
                    <RowDefinition Height="60"/>
                    <!-- use the height of _contactBar_ to make it visible or collapsed. -->
                    <RowDefinition x:Name="_contactBar_"
51
                                   Height="{x:Bind _contactBarHeight, Mode=OneWay}"/>
Nicolas Jager's avatar
Nicolas Jager committed
52 53 54 55 56 57 58
                </Grid.RowDefinitions>
                <Grid Grid.Row="0">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="60"/>
                        <ColumnDefinition Width="*"
                                          MinWidth="200"/>
                    </Grid.ColumnDefinitions>
atraczyk's avatar
atraczyk committed
59
                    <Image x:Name="_XcontactAvatar_"
Nicolas Jager's avatar
Nicolas Jager committed
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75
                           VerticalAlignment="Center"
                           HorizontalAlignment="Center"
                           Grid.Column="0"
                           Width="55"
                           Height="55"
                           Source="Assets\TESTS\contactAvatar.png"/>
                    <!-- visual notifications. -->
                    <Border x:Name="_visualNotificationVideoChat_"
                            Visibility="Collapsed"
                            Style="{StaticResource BorderStyle1}">
                        <TextBlock Text="&#xE8AA;"
                                   Style="{StaticResource TextSegoeStyle1}"/>
                        <Border.RenderTransform>
                            <TranslateTransform X="17" Y="-14"/>
                        </Border.RenderTransform>
                    </Border>
76 77 78 79 80 81
                    <Grid Grid.Column="1">
                        <Grid.RowDefinitions>
                            <RowDefinition Height="30"/>
                            <RowDefinition Height="30"/>
                        </Grid.RowDefinitions>
                        <!-- name of the contact. -->
82 83 84 85
                        <TextBlock  x:Name="_contactName_"
                                    Grid.Row="0"
                                    Text="{x:Bind name_}"
                                    TextTrimming="CharacterEllipsis">
86 87
                        </TextBlock>
                    </Grid>
Nicolas Jager's avatar
Nicolas Jager committed
88 89 90
                </Grid>
            </Grid>
        </DataTemplate>
Nicolas Jager's avatar
Nicolas Jager committed
91 92 93
        <!-- template for AccountListItems. -->
        <DataTemplate x:Key="AccountListItemsTemplate"
                      x:DataType="controls:AccountListItem">
94
            <Grid Margin="0,10">
Nicolas Jager's avatar
Nicolas Jager committed
95
                <Grid.ColumnDefinitions>
96
                    <ColumnDefinition Width="40"/>
97
                    <ColumnDefinition Width="280"/>
Nicolas Jager's avatar
Nicolas Jager committed
98
                </Grid.ColumnDefinitions>
99 100 101 102 103 104
                <Border Grid.Column="0"
                        Margin="5,0"
                        Style="{StaticResource BorderStyle3}">
                    <Image x:Name="_AccountTypeIcon_"
                           VerticalAlignment="Center"
                           HorizontalAlignment="Center"
Nicolas Jager's avatar
Nicolas Jager committed
105
                           Source="{x:Bind  _account.accountType_, Converter={StaticResource _AccountTypeToSourceImage_}, Mode=OneWay}"/>
106 107 108 109 110 111
                </Border>
                <Button x:Name="_editAccountMenuButton_"
                        HorizontalAlignment="Right"
                        VerticalAlignment="Top"
                        Content="&#xE104;"
                        FontFamily="Segoe MDL2 Assets"
112
                        Click="_editAccountMenuButton__Click"
113 114 115
                        FontSize="20"
                        Foreground="White"
                        Background="Transparent"
116 117 118 119
                        BorderThickness="0"
                        Padding="0,4,0,2"
                        Margin="0,0,12,0"
                        Width="28"
120 121 122
                        Visibility="{x:Bind _isSelected, Converter={StaticResource _AccountSelectedToVisibility_}, Mode=OneWay}"
                        Grid.Column="1">
                    <Button.RenderTransform>
123
                        <TranslateTransform Y="-10"/>
124 125 126 127 128
                    </Button.RenderTransform>
                </Button>
                <StackPanel Grid.Column="1">
                    <TextBlock x:Name="_accountName_"
                           Style="{StaticResource TextStyle5}"
129
                           Text="{x:Bind  _account.name_, Mode=OneWay}"/>
130
                    <TextBlock x:Name="_ringID_"
131 132 133 134 135 136 137 138 139
                               Grid.ColumnSpan="2"
                               Style="{StaticResource TextStyle6}"
                               Visibility="{x:Bind  _account.ringID_, Converter={StaticResource _CollapseEmptyString_}, Mode=OneWay}"
                               Text="{x:Bind  _account.ringID_, Mode=OneWay}"/>
                    <TextBlock x:Name="_sipUsername_"
                               Grid.ColumnSpan="2"
                               Visibility="{x:Bind  _account._sipUsername, Converter={StaticResource _CollapseEmptyString_}, Mode=OneWay}"
                               Style="{StaticResource TextStyle6}"
                               Text="{x:Bind  _account._sipUsername, Mode=OneWay}"/>
140
                </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
141 142
            </Grid>
        </DataTemplate>
143 144 145
        <!-- template for smartpanelitems. -->
        <DataTemplate x:Key="SmartPanelItemsTemplate"
                      x:DataType="controls:SmartPanelItem">
146 147
            <Grid PointerEntered="Grid_PointerEntered" PointerExited="Grid_PointerExited" PointerMoved="Grid_PointerMoved"
                  Visibility="{x:Bind  _showMe, Mode=OneWay}">
148
                <Grid.RowDefinitions>
Nicolas Jager's avatar
Nicolas Jager committed
149 150 151
                    <!-- row definition for the contact. -->
                    <RowDefinition Height="auto"/>
                    <!-- row definition for the incoming call bar. -->
152 153
                    <RowDefinition Height="auto"/>
                </Grid.RowDefinitions>
Nicolas Jager's avatar
Nicolas Jager committed
154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172
                <!--helper to detect mouse overing-->
                <Rectangle Fill="Transparent" Grid.Row="0"/>
                <!-- contact. -->
                <Grid Grid.Row="0">
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="310"/>
                    </Grid.ColumnDefinitions>
                    <Grid.RowDefinitions>
                        <RowDefinition Height="60"/>
                        <!-- use the height of _contactBar_ to make it visible or collapsed. -->
                        <RowDefinition x:Name="_contactBar_"
                                       Height="{x:Bind _contact._contactBarHeight, Mode=OneWay}"/>
                    </Grid.RowDefinitions>
                    <Grid Grid.Row="0">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="60"/>
                            <ColumnDefinition Width="*"
                                              MinWidth="200"/>
                        </Grid.ColumnDefinitions>
atraczyk's avatar
atraczyk committed
173 174 175 176 177 178 179 180 181 182 183
                        <Ellipse    Height="50"
                                    Width="50"
                                    Grid.Column="0"
                                    VerticalAlignment="Center"
                                    HorizontalAlignment="Center"
                                    Margin="5">
                            <Ellipse.Fill>
                                <ImageBrush  x:Name="_contactAvatar_"
                                        ImageSource="{x:Bind _contact._avatarImage, Mode=OneWay}"/>
                            </Ellipse.Fill>
                        </Ellipse>
Nicolas Jager's avatar
Nicolas Jager committed
184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231
                        <!-- visual notifications. -->
                        <Border x:Name="_visualNotificationVideoChat_"
                            Visibility="Collapsed"
                            Style="{StaticResource BorderStyle1}">
                            <TextBlock Text="&#xE8AA;"
                                   Style="{StaticResource TextSegoeStyle1}"/>
                            <Border.RenderTransform>
                                <TranslateTransform X="17" Y="-14"/>
                            </Border.RenderTransform>
                        </Border>
                        <Border x:Name="_visualNotificationNewMessage_"
                            Visibility="{x:Bind _contact._unreadMessages, Converter={StaticResource _NewMessageBubleNotification_}, Mode=OneWay}"
                            Style="{StaticResource BorderStyle2}">
                            <TextBlock Text="{x:Bind _contact._unreadMessages, Mode=OneWay}"
                                   Style="{StaticResource TextStyle3}"/>
                            <Border.RenderTransform>
                                <TranslateTransform X="-17" Y="-14"/>
                            </Border.RenderTransform>
                        </Border>

                        <Grid Grid.Column="1">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="30"/>
                                <RowDefinition Height="30"/>
                            </Grid.RowDefinitions>
                            <!-- name of the contact. -->
                            <TextBlock  x:Name="_contactName_"
                                    Grid.Row="0"
                                    Text="{x:Bind _contact.name_}"
                                    TextTrimming="CharacterEllipsis">
                            </TextBlock>
                            <!-- call button. -->
                            <Button Grid.Row="0"
                                    Visibility="{x:Bind _hovered, Mode=OneWay}"
                                    Click="_callContact__Click"
                                    VerticalAlignment="Bottom"
                                    HorizontalAlignment="Left"
                                    Margin="10,0"
                                    Style="{StaticResource roundButtonTemplate}"
                                    FontFamily="Segoe MDL2 Assets"
                                    Content="&#xE116;">
                                <Button.RenderTransform>
                                    <TranslateTransform X="90" Y="25"/>
                                </Button.RenderTransform>
                            </Button>
                        </Grid>
                    </Grid>
                </Grid>
232
                <!-- call bar. -->
Nicolas Jager's avatar
Nicolas Jager committed
233 234 235 236 237 238 239 240
                <Grid Width="320"
                      Grid.Row="1"
                      HorizontalAlignment="Left"
                      Background="DarkGray">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="auto"/>
                        <RowDefinition Height="auto"/>
                    </Grid.RowDefinitions>
241
                    <TextBlock x:Name="_CallStatus_"
Nicolas Jager's avatar
Nicolas Jager committed
242 243
                           Grid.Row="0"
                           Foreground="White"
244 245
                           Text="{x:Bind _callStatus, Mode=OneWay}"
                           Visibility="{x:Bind _callStatus, Converter={StaticResource _HasAnActiveCall_}, Mode=OneWay}"
Nicolas Jager's avatar
Nicolas Jager committed
246 247 248 249 250 251 252 253
                           HorizontalAlignment="Center">
                    </TextBlock>
                    <StackPanel Orientation="Horizontal"
                                Visibility="Visible"
                                Grid.Row="1"
                                HorizontalAlignment="Center">
                        <Button x:Name="_acceptIncomingCallBtn_"
                            Click="_acceptIncomingCallBtn__Click"
254
                            Visibility="{x:Bind _callStatus, Converter={StaticResource _IncomingVisibility_}, Mode=OneWay}"
Nicolas Jager's avatar
Nicolas Jager committed
255 256 257 258 259
                            VerticalAlignment="Center"
                            HorizontalAlignment="Center"
                            Content="Accept"/>
                        <Button x:Name="_rejectIncomingCallBtn_"
                            Click="_rejectIncomingCallBtn__Click"
260
                            Visibility="{x:Bind _callStatus, Converter={StaticResource _IncomingVisibility_}, Mode=OneWay}"
Nicolas Jager's avatar
Nicolas Jager committed
261 262 263 264 265
                            VerticalAlignment="Center"
                            HorizontalAlignment="Center"
                            Content="Reject"/>
                        <Button x:Name="_cancelCallBtn_"
                            Click="_cancelCallBtn__Click"
266
                            Visibility="{x:Bind _callStatus, Converter={StaticResource _OutGoingVisibility_}, Mode=OneWay}"
Nicolas Jager's avatar
Nicolas Jager committed
267 268 269 270 271
                            VerticalAlignment="Center"
                            HorizontalAlignment="Center"
                            Content="Cancel"/>
                    </StackPanel>
                </Grid>
272 273
            </Grid>
        </DataTemplate>
Nicolas Jager's avatar
Nicolas Jager committed
274 275
    </Page.Resources>

Nicolas Jager's avatar
Nicolas Jager committed
276
    <Grid>
Nicolas Jager's avatar
Nicolas Jager committed
277 278 279 280 281 282 283
        <Grid.RowDefinitions>
            <!-- where accounts and share menu drop down are. -->
            <RowDefinition Height="auto"/>
            <!-- where contacts and settings are. -->
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>
        <!-- drop down menus. -->
284
        <Grid Background="#3bc1d3">
Nicolas Jager's avatar
Nicolas Jager committed
285 286 287 288 289 290 291 292 293 294 295 296 297 298 299
            <Grid.RowDefinitions>
                <!-- where the selected account is shown. -->
                <RowDefinition x:Name="_selectedAccountRow_"
                               Height="90"/>
                <!-- where the drop down menus are shown. -->
                <RowDefinition Height="auto"/>
            </Grid.RowDefinitions>
            <!-- selected account. -->
            <Grid Grid.Row="0">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition x:Name="_selectedAccountAvatarColumn_"
                                      Width="90"/>
                    <ColumnDefinition Width="*"/>
                    <ColumnDefinition Width="50"/>
                </Grid.ColumnDefinitions>
300 301 302 303 304
                <Ellipse
                    x:Name="_selectedAccountAvatarContainer_"
                    Height="80"
                    Width="80"
                    Grid.Column="0"
305 306 307 308 309
                    Stroke="White"
                    StrokeThickness="3"
                    PointerEntered="_selectedAccountAvatarContainer__PointerEntered"
                    PointerExited="_selectedAccountAvatarContainer__PointerExited"
                    PointerReleased="_selectedAccountAvatarContainer__PointerReleased"
310 311 312 313 314 315 316
                    Margin="5">
                    <Ellipse.Fill>
                        <ImageBrush
                            x:Name="_selectedAccountAvatar_"
                            ImageSource="Assets\TESTS\contactAvatar.png"/>
                    </Ellipse.Fill>
                </Ellipse>
317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334
                <Ellipse
                    x:Name="_shaderPhotoboothIcon_"
                    Visibility="Collapsed"
                    Height="80"
                    Width="80"
                    Grid.Column="0"
                    IsHitTestVisible="False"
                    Fill="Black"
                    Opacity="0.3"
                    Margin="5">
                </Ellipse>
                <TextBlock x:Name="_photoboothIcon_"
                           Grid.Column="0"
                           Visibility="Collapsed"
                           IsHitTestVisible="False"
                           Style="{StaticResource TextSegoeStyle-Centered-40pt-white}"
                           Text="&#xE722;">
                </TextBlock>
Nicolas Jager's avatar
Nicolas Jager committed
335 336
                <StackPanel Grid.Column="1"
                            VerticalAlignment="Bottom">
337
                    <TextBlock x:Name="_selectedAccountName_"
338
                               Text="[TEXT MISSING]"
339 340
                               Margin="10,0,0,10"
                               TextTrimming="CharacterEllipsis"
Nicolas Jager's avatar
Nicolas Jager committed
341 342 343 344 345 346 347 348 349
                               Style="{StaticResource TextStyle2}"/>
                    <StackPanel Orientation="Horizontal">
                        <!--Content="&#xE0A1;-->
                        <ToggleButton x:Name="_accountsMenuButton_"
                                      VerticalAlignment="Bottom"
                                      Content="&#xE168;"
                                      Checked="_accountsMenuButton__Checked"
                                      Unchecked="_accountsMenuButton__Unchecked"
                                      Style="{StaticResource ToggleButtonStyle1}"/>
350
                        <!-- _shareMenuButton_ -->
Nicolas Jager's avatar
Nicolas Jager committed
351 352 353 354
                        <ToggleButton x:Name="_shareMenuButton_"
                                      VerticalAlignment="Bottom"
                                      Checked="_shareMenuButton__Checked"
                                      Unchecked="_shareMenuButton__Unchecked"
355 356 357 358 359
                                      Style="{StaticResource ToggleButtonStyle1}">
                            <Image Source="Assets/qrCodeIcon.png"
                                   Stretch="Uniform"/>
                        </ToggleButton>
                        <!-- _devicesMenuButton_ -->
360 361
                        <ToggleButton x:Name="_devicesMenuButton_"
                                      VerticalAlignment="Bottom"
362
                                      Content="&#xE836;"
363
                                      Checked="_devicesMenuButton__Checked"
364 365
                                      Unchecked="_devicesMenuButton__Unchecked"
                                      Style="{StaticResource ToggleButtonStyle1}"/>
Nicolas Jager's avatar
Nicolas Jager committed
366 367
                    </StackPanel>
                </StackPanel>
368
                <ToggleButton x:Name="_settingsMenuButton_"
Nicolas Jager's avatar
Nicolas Jager committed
369 370 371
                              Grid.Column="2"
                              VerticalAlignment="Bottom"
                              Content="&#xE115;"
372 373
                              Checked="_settingsMenu__Checked"
                              Unchecked="_settingsMenu__Unchecked"
Nicolas Jager's avatar
Nicolas Jager committed
374 375 376 377
                              Style="{StaticResource ToggleButtonStyle1}"/>
            </Grid>

            <!--sub menus like the accounts list or the share menu are just below, technicaly they are nested inside the
Nicolas Jager's avatar
Nicolas Jager committed
378
            same row. To summon them we use the visibility of their own grid, by linking it to a toggle button-->
Nicolas Jager's avatar
Nicolas Jager committed
379 380 381 382 383 384

            <!-- accounts menu. -->
            <Grid x:Name="_accountsMenuGrid_"
                  MaxHeight="350"
                  Grid.Row="1"
                  Visibility="Collapsed"
385
                  Background="#3bc1d3">
Nicolas Jager's avatar
Nicolas Jager committed
386 387 388 389
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
390 391 392 393
                <ScrollViewer x:Name="_accountsListScrollView_"
                              ScrollViewer.VerticalScrollBarVisibility="Auto"
                              ScrollViewer.VerticalScrollMode="Enabled">
                    <ListBox x:Name="_accountsList_"
Nicolas Jager's avatar
Nicolas Jager committed
394
                         Grid.Row="0"
395
                         SelectionChanged="_accountList__SelectionChanged"
Nicolas Jager's avatar
Nicolas Jager committed
396 397 398
                         Width="320"
                         ItemContainerStyle="{StaticResource contactsListBoxStyle}"
                         Background="#FFE4F1F9"
Nicolas Jager's avatar
Nicolas Jager committed
399
                         ItemTemplate="{StaticResource AccountListItemsTemplate}"/>
400
                </ScrollViewer>
401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417
                <StackPanel Orientation="Horizontal"
                            Grid.Row="1">
                    <!--Style="{StaticResource ButtonStyle6}"-->
                    <Button x:Name="_addAccountBtn_"
                            VerticalAlignment="Center"
                            HorizontalAlignment="Center"
                            Content="&#xE948;"
                            Click="_addAccountBtn__Click"
                            Style="{StaticResource ButtonStyle5}"/>
                    <!--Style="{StaticResource ButtonStyle6}"-->
                    <Button x:Name="_linkThisDeviceBtn_"
                            VerticalAlignment="Center"
                            HorizontalAlignment="Center"
                            Content="&#xEBD2;"
                            Click="_linkThisDeviceBtn__Click"
                            Style="{StaticResource ButtonStyle5}"/>
                </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
418 419 420 421 422
            </Grid>
            <!-- account creation menu. -->
            <Grid x:Name="_accountCreationMenuGrid_"
                  Grid.Row="2"
                  Visibility="Collapsed"
423
                  Background="#3bc1d3">
Nicolas Jager's avatar
Nicolas Jager committed
424 425 426 427
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
Nicolas Jager's avatar
Nicolas Jager committed
428 429 430 431 432 433 434 435
                <ScrollViewer Grid.Row="0"
                              MaxHeight="400">
                    <StackPanel Orientation="Vertical"
                                Padding="10,0"
                                Background="#FFE4F1F9">
                        <!-- alias sub menu. -->
                        <StackPanel Orientation="Horizontal"
                                    Margin="0,20">
436
                            <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
Nicolas Jager's avatar
Nicolas Jager committed
437 438 439
                                       Margin="0,0,10,0"
                                       Text="&#xE8EC;"/>
                            <TextBlock Text="Alias"/>
440
                        </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465
                        <Grid Margin="10,0,10,10">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*"/>
                                <ColumnDefinition Width="25"/>
                            </Grid.ColumnDefinitions>
                            <TextBox  x:Name="_accountAliasTextBox_"
                                      Grid.Column="0"
                                      TextChanged="_accountAliasTextBox__TextChanged"
                                      PlaceholderText="Enter alias"/>
                            <TextBlock x:Name="_accountAliasValid_"
                                               Grid.Column="1"
                                               Padding="10,0"
                                               Style="{StaticResource TextSegoeStyle-20pt-green}"
                                               Visibility="Collapsed"
                                               Text="&#xE10B;"/>
                            <TextBlock x:Name="_accountAliasInvalid_"
                                               Grid.Column="1"
                                               Padding="10,0"
                                               Style="{StaticResource TextSegoeStyle-20pt-red}"
                                               Text="&#xE10A;"/>
                        </Grid>

                        <!-- account type chooser -->
                        <StackPanel Orientation="Horizontal"
                                    Margin="0,20">
466
                            <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
Nicolas Jager's avatar
Nicolas Jager committed
467 468 469
                                       Margin="0,0,10,0"
                                       Text="&#xE168;"/>
                            <TextBlock Text="Account type"/>
470
                        </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492
                        <ComboBox x:Name="_accountTypeComboBox_"
                                      SelectedIndex="0"
                                      Margin="10,10,0,0"
                                      SelectionChanged="_accountTypeComboBox__SelectionChanged"
                                      VerticalAlignment="Center"
                                      Width="195">
                            <ComboBoxItem Content="Ring"/>
                            <ComboBoxItem Content="Sip"/>
                        </ComboBox>
                        <!-- RING account. -->
                        <StackPanel x:Name="_ringAccountCreationStack_"
                                    Margin="0,20"
                                    Visibility="Visible">
                            <!-- register account on blockachain -->
                            <StackPanel Orientation="Horizontal"
                                        Margin="0,20">
                                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
                                           Margin="0,0,10,0"
                                           Text="&#xE167;"/>
                                <TextBlock Text="Register public username"/>
                            </StackPanel>
                            <ToggleSwitch x:Name="_RegisterState_"
493
                                      IsOn="True"
Nicolas Jager's avatar
Nicolas Jager committed
494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605
                                      Toggled="_RegisterState__Toggled"
                                      Margin="0,10"/>
                            <TextBlock x:Name="_whatWilHappen_"
                                       Margin="0,10,0,0"
                                       Style="{StaticResource BodyTextBlockStyle}"
                                       Text="peoples will find you with your username"/>
                            <HyperlinkButton Content="Learn more"
                                             Margin="0,0,0,10"
                                             NavigateUri="http://ring.cx"/>
                            <Grid Margin="10">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="25"/>
                                </Grid.ColumnDefinitions>
                                <TextBox x:Name="_usernameTextBox_"
                                         Grid.Column="0"
                                         PlaceholderText="Enter your full name"
                                         KeyUp="_usernameTextBox__KeyUp"
                                                 />
                                <TextBlock x:Name="_usernameValid_"
                                                   Grid.Column="1"
                                                   Padding="10,0"
                                                   Style="{StaticResource TextSegoeStyle-20pt-green}"
                                                   Visibility="Collapsed"
                                                   Text="&#xE10B;"/>
                                <TextBlock x:Name="_usernameInvalid_"
                                                   Grid.Column="1"
                                                   Padding="10,0"
                                                   Style="{StaticResource TextSegoeStyle-20pt-red}"
                                                   Text="&#xE10A;"/>
                            </Grid>
                            <!-- password sub menu. -->
                            <StackPanel Orientation="Horizontal"
                                        Margin="0,20">
                                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
                                        Margin="0,0,10,0"
                                       Text="&#xE8D7;"/>
                                <TextBlock Text="Archive password"/>
                            </StackPanel>
                            <Grid Margin="10">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="25"/>
                                </Grid.ColumnDefinitions>
                                <PasswordBox x:Name="_ringPasswordBoxAccountCreation_"
                                             Grid.Column="0"
                                             PasswordChanged="_passwordBoxAccountCreationCheck__PasswordChanged"
                                             PlaceholderText="Enter password"/>
                                <TextBlock x:Name="_passwordValid_"
                                           Grid.Column="1"
                                           Padding="10,0"
                                           Style="{StaticResource TextSegoeStyle-20pt-green}"
                                           Visibility="Collapsed"
                                           Text="&#xE10B;"/>
                                <TextBlock x:Name="_passwordInvalid_"
                                           Grid.Column="1"
                                           Padding="10,0"
                                           Style="{StaticResource TextSegoeStyle-20pt-red}"
                                           Text="&#xE10A;"/>
                            </Grid>
                            <Grid Margin="10">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="25"/>
                                </Grid.ColumnDefinitions>
                                <PasswordBox x:Name="_ringPasswordBoxAccountCreationCheck_"
                                             Grid.Column="0"
                                             PasswordChanged="_passwordBoxAccountCreationCheck__PasswordChanged"
                                             PlaceholderText="Repeat password"/>
                                <TextBlock x:Name="_passwordCheckValid_"
                                           Grid.Column="1"
                                           Padding="10,0"
                                           Style="{StaticResource TextSegoeStyle-20pt-green}"
                                           Visibility="Collapsed"
                                           Text="&#xE10B;"/>
                                <TextBlock x:Name="_passwordCheckInvalid_"
                                           Grid.Column="1"
                                           Padding="10,0"
                                           Style="{StaticResource TextSegoeStyle-20pt-red}"
                                           Text="&#xE10A;"/>
                            </Grid>
                            <!-- upnp sub menu. -->
                            <StackPanel Orientation="Horizontal"
                                        Margin="0,20">
                                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
                                            Margin="0,0,10,0"
                                           Text="&#xE15E;"/>
                                <TextBlock Text="UPnP"/>
                            </StackPanel>
                            <ToggleSwitch x:Name="_upnpStateAccountCreation_"
                                          IsOn="True"
                                          Margin="0,10"/>
                        </StackPanel>
                        <!-- SIP account. -->
                        <StackPanel x:Name="_sipAccountCreationStack_"
                                    Visibility="Collapsed">
                            <StackPanel Orientation="Horizontal"
                                        Margin="10">
                                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
                                           Text="&#xE717;"/>
                                <TextBlock Text="SIP account parameters"
                                           Margin="10"/>
                            </StackPanel>
                            <TextBox  x:Name="_sipHostnameTextBox_"
                                      Margin="10"
                                      PlaceholderText="Enter hostname"/>
                            <TextBox  x:Name="_sipUsernameTextBox_"
                                      Margin="10"
                                      PlaceholderText="Enter username"/>
                            <PasswordBox x:Name="_sipPasswordBoxAccountCreation_"
                                         Margin="10"
                                         PlaceholderText="Enter password"/>
606
                        </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
607
                    </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
608 609
                </ScrollViewer>

Nicolas Jager's avatar
Nicolas Jager committed
610 611 612 613 614 615 616 617 618 619
                <!-- buttons yes/no to create the new account. -->
                <Grid Grid.Row="1">
                    <StackPanel Orientation="Horizontal"
                                HorizontalAlignment="Center">
                        <Button x:Name="_createAccountYes_"
                                Grid.Row="1"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Center"
                                Content="&#xE081;"
                                Click="_createAccountYes__Click"
620
                                Style="{StaticResource ButtonStyle5}"/>
Nicolas Jager's avatar
Nicolas Jager committed
621 622 623 624 625 626
                        <Button x:Name="_createAccountNo_"
                                Grid.Row="1"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Center"
                                Content="&#xE106;"
                                Click="_createAccountNo__Click"
627
                                Style="{StaticResource ButtonStyle5}"/>
Nicolas Jager's avatar
Nicolas Jager committed
628 629 630
                    </StackPanel>
                </Grid>
            </Grid>
631 632 633 634
            <!-- add account menu. -->
            <Grid x:Name="_accountAddMenuGrid_"
                  Visibility="Collapsed"
                  Grid.Row="2"
635
                  Background="#3bc1d3">
636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716
                <Grid.RowDefinitions>
                    <RowDefinition Height="auto"/>
                    <RowDefinition Height="auto"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
                <StackPanel Orientation="Horizontal"
                            Background="#FFE4F1F9"
                            Padding="10"
                                    Grid.Row="0">
                    <Button x:Name="_step1button_"
                            Click="_step1button__Click"
                            Content="Step 1"/>
                    <TextBlock Text=">"/>
                    <Button x:Name="_step2button_"
                            Click="_step2button__Click"
                            Content="Step 2"/>
                </StackPanel>
                <!-- step 1. -->
                <StackPanel x:Name="_step1Menu_"
                                    Background="#FFE4F1F9"
                                    Padding="10"
                                    Grid.Row="1">
                    <TextBlock Text="To link this device to a Ring account, you'll first need to generate a PIN from Ring on a device hosting the account."
                                        TextWrapping="Wrap"
                                        TextAlignment="Justify"/>
                    <HyperlinkButton Content="Learn more"
                                                Margin="0,0,0,10"
                                                NavigateUri="http://ring.cx"/>
                </StackPanel>
                <!-- step 2. -->
                <StackPanel x:Name="_step2Menu_"
                                    Background="#FFE4F1F9"
                                    Visibility="Collapsed"
                                    Grid.Row="1">
                    <TextBox  x:Name="_PINTextBox_"
                                    Margin="10"
                                    GotFocus="_PINTextBox__GotFocus"
                                    PlaceholderText="Enter PIN"/>
                    <PasswordBox x:Name="_ArchivePassword_"
                                    Margin="10"
                                    PlaceholderText="Enter your password"/>
                    <TextBlock x:Name="_response_"
                               Foreground="Red"
                               HorizontalAlignment="Center"
                               Text=""/>
                </StackPanel>
                <!-- buttons next step and yes/no to add the account. -->
                <Grid Grid.Row="2">
                    <StackPanel Orientation="Horizontal"
                                        Padding="10,0"
                                        HorizontalAlignment="Center">
                        <Button x:Name="_nextstep_"
                                        VerticalAlignment="Center"
                                        HorizontalAlignment="Center"
                                        Content="&#xE081;"
                                        Click="_step2button__Click"
                                        Style="{StaticResource ButtonStyle2}"/>
                        <Button x:Name="_addAccountYes_"
                                        VerticalAlignment="Center"
                                        HorizontalAlignment="Center"
                                        Visibility="Collapsed"
                                        Content="&#xE081;"
                                        Click="_addAccountYes__Click"
                                        Style="{StaticResource ButtonStyle5}"/>
                        <Button x:Name="_addAccountNo_"
                                        VerticalAlignment="Center"
                                        HorizontalAlignment="Center"
                                        Visibility="Collapsed"
                                        Content="&#xE106;"
                                        Click="_addAccountNo__Click"
                                        Style="{StaticResource ButtonStyle5}"/>
                    </StackPanel>
                </Grid>
            </Grid>
            <!--<StackPanel Orientation="Horizontal"
                                Margin="0,20">
                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
                                    Margin="0,0,10,0"
                                    Text="&#xE8EC;"/>
                <TextBlock Text="Alias"/>
            </StackPanel>-->
717
            <!-- account edition menu. -->
Nicolas Jager's avatar
Nicolas Jager committed
718
            <Grid x:Name="_accountEditionGrid_"
719 720
                  Grid.Row="2"
                  Visibility="Collapsed"
721
                  Background="#3bc1d3">
722 723 724 725
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
Nicolas Jager's avatar
Nicolas Jager committed
726 727 728 729 730 731 732 733 734 735
                <ScrollViewer x:Name="_scrollViewerEditionMenu_"
                              Grid.Row="0"
                              MaxHeight="400">
                    <StackPanel Orientation="Vertical"
                                Padding="10,0"
                                Grid.Row="0"
                                Background="#FFE4F1F9">
                        <!-- alias sub menu. -->
                        <StackPanel Orientation="Horizontal"
                                    Margin="0,20">
736
                            <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
Nicolas Jager's avatar
Nicolas Jager committed
737 738 739
                                       Margin="0,0,10,0"
                                       Text="&#xE8EC;"/>
                            <TextBlock Text="Alias"/>
740
                        </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761
                        <Grid Margin="10,0,10,10">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*"/>
                                <ColumnDefinition Width="25"/>
                            </Grid.ColumnDefinitions>
                            <TextBox  x:Name="_accountAliasTextBoxEdition_"
                                      Grid.Column="0"
                                      TextChanged="_accountAliasTextBoxEdition__TextChanged"
                                      PlaceholderText="Enter alias"/>
                            <TextBlock x:Name="_accountAliasValidEdition_"
                                               Grid.Column="1"
                                               Padding="10,0"
                                               Style="{StaticResource TextSegoeStyle-20pt-green}"
                                               Visibility="Collapsed"
                                               Text="&#xE10B;"/>
                            <TextBlock x:Name="_accountAliasInvalidEdition_"
                                               Grid.Column="1"
                                               Padding="10,0"
                                               Style="{StaticResource TextSegoeStyle-20pt-red}"
                                               Text="&#xE10A;"/>
                        </Grid>
762
                        <!-- edition sub menu. -->
Nicolas Jager's avatar
Nicolas Jager committed
763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813
                        <StackPanel x:Name="_ringStackEdition_">
                            <!-- register account on blockachain -->
                            <StackPanel Orientation="Horizontal"
                                        Margin="0,20">
                                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
                                           Margin="0,0,10,0"
                                           Text="&#xE167;"/>
                                <TextBlock Text="Register public username"/>
                            </StackPanel>
                            <ToggleSwitch x:Name="_RegisterStateEdition_"
                                      IsOn="True"
                                      Toggled="_RegisterStateEdition__Toggled"
                                      Margin="0,10"/>
                            <TextBlock x:Name="_whatWilHappenEdition_"
                                       Margin="0,10,0,0"
                                       Style="{StaticResource BodyTextBlockStyle}"
                                       Text="peoples will find you with your username"/>
                            <HyperlinkButton Content="Learn more"
                                             Margin="0,0,0,10"
                                             NavigateUri="http://ring.cx"/>
                            <Grid Margin="10">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="*"/>
                                    <ColumnDefinition Width="25"/>
                                </Grid.ColumnDefinitions>
                                <TextBox x:Name="_usernameTextBoxEdition_"
                                         Grid.Column="0"
                                         PlaceholderText="Enter your full name"
                                         KeyUp="_usernameTextBoxEdition__KeyUp"/>
                                <TextBlock x:Name="_usernameValidEdition_"
                                                   Grid.Column="1"
                                                   Padding="10,0"
                                                   Style="{StaticResource TextSegoeStyle-20pt-green}"
                                                   Visibility="Collapsed"
                                                   Text="&#xE10B;"/>
                                <TextBlock x:Name="_usernameInvalidEdition_"
                                                   Grid.Column="1"
                                                   Padding="10,0"
                                                   Style="{StaticResource TextSegoeStyle-20pt-red}"
                                                   Text="&#xE10A;"/>
                            </Grid>
                            <Button x:Name="_registerOnBlockchainEdition_"
                                Content="register"
                                Visibility="Collapsed"
                                Click="_registerOnBlockchainEdition__Click"/>
                            <StackPanel Orientation="Horizontal" Margin="10">
                                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
                                       Text="&#xE15E;"/>
                                <TextBlock Text="UPnP" Margin="10"/>
                            </StackPanel>
                            <ToggleSwitch x:Name="_upnpState_"
814
                                      Margin="20,10"/>
Nicolas Jager's avatar
Nicolas Jager committed
815 816 817
                        </StackPanel>
                        <!-- SIP parameters. -->
                        <StackPanel x:Name="_sipAccountStackEdition_"
818
                                Visibility="Collapsed">
Nicolas Jager's avatar
Nicolas Jager committed
819
                            <StackPanel Orientation="Horizontal"
820
                                    Margin="10">
Nicolas Jager's avatar
Nicolas Jager committed
821
                                <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
822
                                       Text="&#xE717;"/>
Nicolas Jager's avatar
Nicolas Jager committed
823
                                <TextBlock Text="SIP account parameters"
824
                                       Margin="10"/>
Nicolas Jager's avatar
Nicolas Jager committed
825 826
                            </StackPanel>
                            <TextBox  x:Name="_sipHostnameEdition_"
827 828
                                  Margin="10"
                                  PlaceholderText="Enter hostname"/>
Nicolas Jager's avatar
Nicolas Jager committed
829
                            <TextBox  x:Name="_sipUsernameEditionTextBox_"
830 831
                                  Margin="10"
                                  PlaceholderText="Enter username"/>
Nicolas Jager's avatar
Nicolas Jager committed
832
                            <PasswordBox x:Name="_sipPasswordEdition_"
833 834
                                     Margin="10"
                                     PlaceholderText="Enter password"/>
Nicolas Jager's avatar
Nicolas Jager committed
835 836 837 838
                        </StackPanel>
                        <!-- delete account sub menu. -->
                        <StackPanel Orientation="Horizontal" Margin="10">
                            <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
839
                                   Text="&#xE74D;"/>
Nicolas Jager's avatar
Nicolas Jager committed
840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861
                            <TextBlock Text="Delete account" Margin="10"/>
                        </StackPanel>
                        <ToggleSwitch x:Name="_deleteAccountEdition_"
                                      Toggled="_deleteAccountEdition__Toggled"
                                      Margin="20,10"/>
                        <TextBlock x:Name="_whatWilHappendeleteRingAccountEdition_"
                                   Margin="0,10,0,0"
                                   Style="{StaticResource BodyTextBlockStyle}"
                                   Foreground="Red"
                                   Visibility="Collapsed"
                                   Text="Your account will be deleted from this computer. Other devices are not affected. Your public registration can never be deleted."/>
                        <TextBlock x:Name="_whatWilHappendeleteSipAccountEdition_"
                                   Margin="0,10,0,0"
                                   Style="{StaticResource BodyTextBlockStyle}"
                                   Foreground="Red"
                                   Visibility="Collapsed"
                                   Text="Your account will be deleted from this computer."/>
                        <HyperlinkButton x:Name="_learnMoreDeleteAccountEdition_"
                                         Content="Learn more"
                                         Visibility="Collapsed"
                                         Margin="0,0,0,10"
                                         NavigateUri="http://ring.cx"/>
862
                    </StackPanel>
Nicolas Jager's avatar
Nicolas Jager committed
863
                </ScrollViewer>
864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884
                <!-- buttons yes/no to accept the modification. -->
                <Grid Grid.Row="1">
                    <StackPanel Orientation="Horizontal"
                                HorizontalAlignment="Center">
                        <Button x:Name="_acceptAccountModification_"
                                Grid.Row="1"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Center"
                                Content="&#xE081;"
                                Click="_acceptAccountModification__Click"
                                Style="{StaticResource ButtonStyle5}"/>
                        <Button x:Name="_cancelAccountModification_"
                                Grid.Row="1"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Center"
                                Content="&#xE106;"
                                Click="_cancelAccountModification__Click"
                                Style="{StaticResource ButtonStyle5}"/>
                    </StackPanel>
                </Grid>
            </Grid>
Nicolas Jager's avatar
Nicolas Jager committed
885 886 887 888
            <!-- share menu. -->
            <Grid x:Name="_shareMenuGrid_"
                  Grid.Row="2"
                  Visibility="Collapsed"
889
                  Background="#3bc1d3">
Nicolas Jager's avatar
Nicolas Jager committed
890 891 892 893 894 895 896 897 898 899
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
                <Grid Background="#FFE4F1F9">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="*"/>
                        <RowDefinition Height="auto"/>
                        <RowDefinition Height="auto"/>
                    </Grid.RowDefinitions>
900 901
                    <Grid Background="white"
                          Margin="10"
902
                          MaxHeight="140"
903 904 905
                          MaxWidth="140"
                          Padding="5">
                        <Image x:Name="_selectedAccountQrCode_"
Nicolas Jager's avatar
Nicolas Jager committed
906 907 908
                           Width="200"
                           Margin="5"
                           Grid.Row="0"
909
                           Stretch="None"
Nicolas Jager's avatar
Nicolas Jager committed
910
                           Height="200"/>
911 912 913 914 915
                    </Grid>
                    <TextBlock x:Name="_ringId_"
                               Padding="5"
                               Style="{StaticResource TextStyle4}"
                               Text=""
Nicolas Jager's avatar
Nicolas Jager committed
916
                               Grid.Row="1"
917
                               IsTextSelectionEnabled="True"
Nicolas Jager's avatar
Nicolas Jager committed
918 919
                               HorizontalAlignment="Center"/>
                </Grid>
920 921 922 923 924 925 926
                <Button x:Name="_shareMenuDone_"
                        Grid.Row="1"
                        VerticalAlignment="Center"
                        HorizontalAlignment="Center"
                        Content="&#xE081;"
                        Click="_shareMenuDone__Click"
                        Style="{StaticResource ButtonStyle6}"/>
Nicolas Jager's avatar
Nicolas Jager committed
927
            </Grid>
928 929 930 931
            <!-- devices menu. -->
            <Grid x:Name="_devicesMenuGrid_"
                  Grid.Row="2"
                  Visibility="Collapsed"
932
                  Background="#3bc1d3">
933 934 935 936 937 938
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
                <Grid Background="#FFE4F1F9">
                    <Grid.RowDefinitions>
939
                        <RowDefinition Height="auto"/>
940
                        <RowDefinition Height="auto"/>
941 942 943 944 945
                        <RowDefinition Height="auto"/>
                        <RowDefinition Height="*"/>
                        <RowDefinition Height="auto"/>
                        <RowDefinition Height="auto"/>
                    </Grid.RowDefinitions>
946
                    <!-- about this device -->
947
                    <StackPanel Orientation="Horizontal"
948 949
                                    Grid.Row="0"
                                    Margin="10,20">
950
                        <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
951 952
                                       Margin="0,0,10,0"
                                       Text="&#xE211;"/>
953 954
                        <TextBlock Text="Your device ID"/>
                    </StackPanel>
955
                    <TextBlock x:Name="_deviceId_"
Nicolas Jager's avatar
Nicolas Jager committed
956
                               Margin="10"
957
                               Text="[TEXT_MISSING]"
Nicolas Jager's avatar
Nicolas Jager committed
958
                               TextTrimming="CharacterEllipsis"
959
                               FontSize="12"
960 961 962
                               Grid.Row="1"
                               IsTextSelectionEnabled="True"
                               HorizontalAlignment="Center"/>
963 964
                    <!-- about linked devices -->
                    <StackPanel Orientation="Horizontal"
965 966
                                    Grid.Row="2"
                                    Margin="10,20">
967
                        <TextBlock Style="{StaticResource TextSegoeStyle-20pt-black}"
968 969
                                       Margin="0,0,10,0"
                                       Text="&#xEBD2;"/>
970 971 972
                        <TextBlock Text="other linked devices"/>
                    </StackPanel>
                    <TextBlock x:Name="_waitingDevicesList_"
Nicolas Jager's avatar
Nicolas Jager committed
973
                               Text="waiting for devices list..."
974
                               Grid.Row="3"
Nicolas Jager's avatar
Nicolas Jager committed
975 976
                               IsTextSelectionEnabled="True"
                               HorizontalAlignment="Center"/>
977
                    <ListBox x:Name="_devicesIdList_"
Nicolas Jager's avatar
Nicolas Jager committed
978
                             Visibility="Collapsed"
979 980 981
                             Padding="10,0"
                             Background="#FFE4F1F9"
                             Grid.Row="3"/>
982
                </Grid>
983
                <!-- button to add device. -->
984 985 986 987 988 989 990 991
                <Button x:Name="_addDevice_"
                        Grid.Row="1"
                        VerticalAlignment="Center"
                        HorizontalAlignment="Center"
                        Content="&#xE948;"
                        Click="_addDevice__Click"
                        Style="{StaticResource ButtonStyle6}"/>
            </Grid>
992 993 994 995
            <!-- add device (pin generator) menu. -->
            <Grid x:Name="_addingDeviceGrid_"
                  Grid.Row="2"
                  Visibility="Collapsed"
996
                  Background="#3bc1d3">
997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
                <Grid Background="#FFE4F1F9">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="auto"/>
                        <RowDefinition Height="auto"/>
                        <RowDefinition Height="*"/>
                    </Grid.RowDefinitions>
                    <TextBlock VerticalAlignment="Center"
                                       Text="PIN generator"
                               HorizontalAlignment="Center"
                               Grid.Row="0"
                                       Margin="10,10,0,10"/>
                    <PasswordBox x:Name="_passwordForPinGenerator_"
                                 Margin="10"
                                 Grid.Row="1"
                                 PlaceholderText="Enter your password"/>
                </Grid>
                <!-- buttons yes/no to generate a PIN. -->
                <Grid Grid.Row="1">
                    <StackPanel Orientation="Horizontal"
                                HorizontalAlignment="Center">
                        <Button x:Name="_pinGeneratorYes_"
                                Grid.Row="1"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Center"
                                Content="&#xE081;"
                                Click="_pinGeneratorYes__Click"
                                Style="{StaticResource ButtonStyle5}"/>
                        <Button x:Name="_pinGeneratorNo_"
                                Grid.Row="1"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Center"
                                Content="&#xE106;"
                                Click="_pinGeneratorNo__Click"
                                Style="{StaticResource ButtonStyle5}"/>
                    </StackPanel>
                </Grid>
            </Grid>
            <!-- waiting for a PIN. -->
            <Grid x:Name="_waitingForPin_"
                Grid.Row="2"
                Visibility="Collapsed"
1042
                Background="#3bc1d3">
1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="30"/>
                </Grid.RowDefinitions>
                <Grid Background="#FFE4F1F9">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="*"/>
                        <RowDefinition Height="auto"/>
                        <RowDefinition Height="*"/>
                    </Grid.RowDefinitions>
                    <TextBlock x:Name="_waitingAndResult_"
                               VerticalAlignment="Center"
                               Text="Exporting account on the Ring..."
                               HorizontalAlignment="Center"
                               Grid.Row="0"
                               Margin="10,10,0,10"/>
                </Grid>
Nicolas Jager's avatar
Nicolas Jager committed
1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071
                <Grid Grid.Row="1">
                    <StackPanel Orientation="Horizontal"
                                HorizontalAlignment="Center">
                        <Button x:Name="_closePin_"
                                Grid.Row="1"
                                VerticalAlignment="Center"
                                HorizontalAlignment="Center"
                                Content="&#xE081;"
                                Click="_closePin__Click"
                                Style="{StaticResource ButtonStyle5}"/>
                    </StackPanel>
                </Grid>
1072
            </Grid>
Nicolas Jager's avatar
Nicolas Jager committed
1073

Nicolas Jager's avatar
Nicolas Jager committed
1074
        </Grid>
1075
        <!-- smartList and settings. -->
Nicolas Jager's avatar
Nicolas Jager committed
1076
        <Grid Grid.Row="1">
1077
            <!-- contacts + calls => smartpanelitems. -->
Nicolas Jager's avatar
Nicolas Jager committed
1078 1079 1080 1081 1082
            <Grid x:Name="_smartGrid_"
                  Grid.Row="0">
                <Grid.RowDefinitions>
                    <RowDefinition x:Name="_rowRingTxtBx_"
                                   Height="40"/>
1083
                    <RowDefinition Height="auto"/>
Nicolas Jager's avatar
Nicolas Jager committed
1084 1085
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115
                <Grid>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="*"/>
                        <ColumnDefinition Width="Auto"/>
                    </Grid.ColumnDefinitions>
                    <Border     x:Name="BackgroundElement"
                                Grid.Column="0"
                                Background="White"
                                Margin="6"
                                Opacity="1"
                                Grid.ColumnSpan="2">
                    </Border>
                    <TextBox    x:Name="_ringTxtBx_"
                                Grid.Column="0"
                                VerticalAlignment="Center"
                                BorderThickness="0"
                                HorizontalAlignment="Stretch"
                                Padding="4"
                                Margin="6"
                                Foreground="Black"
                                Background="White"
                                TextWrapping="Wrap"
                                KeyDown="_ringTxtBx__KeyDown"
                                KeyUp="_ringTxtBx__KeyUp"
                                Text="">
                    </TextBox>
                    <Button     x:Name="_addButton_"
                                Background="Transparent"
                                Grid.Column="1"
                                FontFamily="Segoe MDL2 Assets"
1116
                                Foreground="#3bc1d3"
1117 1118 1119 1120
                                Content=" &#xE1E2;"
                                Click="_ringTxtBx__Click"
                                BorderThickness="0"
                                Visibility="Visible"
1121
                                IsTabStop="False"
1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140
                                FontSize="20"
                                Width="38"
                                Margin="6"
                                Padding="4,4,8,4"
                                VerticalAlignment="Stretch">
                        <Button.RenderTransform>
                            <TranslateTransform X="0"/>
                        </Button.RenderTransform>
                    </Button>
                </Grid>
                <ListBox    x:Name="_smartList_"
                            Grid.Row="2"
                            Margin="0"
                            Padding="0"
                            SelectionChanged="_smartList__SelectionChanged"
                            ScrollViewer.HorizontalScrollBarVisibility="Auto"
                            ScrollViewer.HorizontalScrollMode="Enabled"
                            ItemContainerStyle="{StaticResource contactsListBoxStyle}"
                            ItemTemplate="{StaticResource SmartPanelItemsTemplate}"/>
Nicolas Jager's avatar
Nicolas Jager committed
1141 1142
            </Grid>
            <!-- settings. -->
1143
            <Grid x:Name="_settingsMenu_"
Nicolas Jager's avatar
Nicolas Jager committed
1144
                  Grid.Row="0"
1145 1146
                  Visibility="Collapsed"
                  Background="#FFE4F1F9">
1147 1148 1149
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
1150 1151
                <ScrollViewer
                    ScrollViewer.VerticalScrollBarVisibility="Auto">
1152
                    <Grid x:Name="_videoSettings_"
1153
                      Grid.Row="0">
1154 1155
                        <StackPanel Margin="10">
                            <TextBlock Text="Video Device"
1156
                                   Margin="10"/>
1157
                            <ComboBox x:Name="_videoDeviceComboBox_"
1158 1159
                                  Margin="10"
                                  SelectionChanged="_videoDeviceComboBox__SelectionChanged">
1160 1161 1162
                            </ComboBox>
                            <TextBlock Text="Video Resolution" Margin="10"/>
                            <ComboBox x:Name="_videoResolutionComboBox_"
1163 1164
                                  Margin="10"
                                  SelectionChanged="_videoResolutionComboBox__SelectionChanged">
1165 1166 1167
                            </ComboBox>
                            <TextBlock Text="Video Rate" Margin="10"/>
                            <ComboBox x:Name="_videoRateComboBox_"
1168 1169
                                  Margin="10"
                                  SelectionChanged="_videoRateComboBox__SelectionChanged">
1170 1171 1172 1173
                            </ComboBox>
                        </StackPanel>
                    </Grid>
                </ScrollViewer>
Nicolas Jager's avatar
Nicolas Jager committed
1174 1175
            </Grid>
        </Grid>
Nicolas Jager's avatar
Nicolas Jager committed
1176 1177 1178
    </Grid>

</Page>