diff --git a/.gitignore b/.gitignore index 85b9272e82b40ff73f91a2b5023dd9dc6c9df350..9245c7ac0f2efee573c9569ea62958ad707e133f 100644 --- a/.gitignore +++ b/.gitignore @@ -80,6 +80,7 @@ artifacts/ *.pidb *.svclog *.scc +*.appx # Chutzpah Test files _Chutzpah* diff --git a/AboutPage.xaml b/AboutPage.xaml index c46a2aa58b112023888208c6552b6b5e8ba03190..9d2188993cec6adeb79cd491e5e757c06aa63c93 100644 --- a/AboutPage.xaml +++ b/AboutPage.xaml @@ -72,7 +72,7 @@ VerticalScrollBarVisibility="Hidden"> <StackPanel MaxWidth="500" Width="310"> - <TextBlock Text="Ring version: 2017/1/3" + <TextBlock Text="Ring version: 2017/2/13" TextWrapping="Wrap" TextAlignment="Justify" Margin="0,0,0,24" diff --git a/App.xaml.cpp b/App.xaml.cpp index 680e398c2851c67550b8be57a18cc712d78b0821..bd872ac919b4ec9525fe1771f34903b8e24d4b18 100644 --- a/App.xaml.cpp +++ b/App.xaml.cpp @@ -20,6 +20,7 @@ #include "LoadingPage.xaml.h" #include "MainPage.xaml.h" #include "Wizard.xaml.h" +#include "VideoPage.xaml.h" using namespace Windows::ApplicationModel::Core; using namespace Windows::Foundation; diff --git a/Globals.h b/Globals.h index c92d2dd4c42b1ed995db2bbb70d90e75fddac3a2..f947bddcd377502c112b40fe58d61107d2a8d141 100644 --- a/Globals.h +++ b/Globals.h @@ -11,7 +11,8 @@ public enum class CallStatus { PAUSED, PEER_PAUSED, ENDED, - TERMINATING + TERMINATING, + CONNECTED }; public enum class LookupStatus { diff --git a/MainPage.xaml.cpp b/MainPage.xaml.cpp index 5bb65db3b58059e5907406d463ee2302d330bf40..6d78153e599cdb843f2b4cbddde46033ab4110fb 100644 --- a/MainPage.xaml.cpp +++ b/MainPage.xaml.cpp @@ -78,6 +78,7 @@ MainPage::MainPage() auto videoPage = dynamic_cast<VideoPage^>(_videoFrame_->Content); videoPage->pressHangUpCall += ref new RingClientUWP::PressHangUpCall(this, &RingClientUWP::MainPage::OnpressHangUpCall); + auto messageTextFrame = dynamic_cast<MessageTextPage^>(_messageTextFrame_->Content); messageTextFrame->closeMessageTextPage += ref new RingClientUWP::CloseMessageTextPage(this, &RingClientUWP::MainPage::OncloseMessageTextPage); @@ -102,6 +103,8 @@ MainPage::MainPage() auto brush = ref new Windows::UI::Xaml::Media::SolidColorBrush(col); _loadingStatus_->Foreground = brush; }); + + RingD::instance->toggleFullScreen += ref new RingClientUWP::ToggleFullScreen(this, &RingClientUWP::MainPage::OnToggleFullScreen); } void @@ -378,3 +381,17 @@ void RingClientUWP::MainPage::OnvolatileDetailsChanged(const std::string &accoun { showLoadingOverlay(false, false); } + +void RingClientUWP::MainPage::OnToggleFullScreen(bool state) +{ + static bool openState; + if (state == true) { + openState = _innerSplitView_->IsPaneOpen; + _innerSplitView_->IsPaneOpen = false; + _innerSplitView_->CompactPaneLength = 0; + } + else { + _innerSplitView_->IsPaneOpen = openState; + _innerSplitView_->CompactPaneLength = 60; + } +} \ No newline at end of file diff --git a/MainPage.xaml.h b/MainPage.xaml.h index efa59b673cb693ec5f24b8e7706e2f9f04c5a53c..4c8a5b25a830cba003b86e071f3592556dbb1222 100644 --- a/MainPage.xaml.h +++ b/MainPage.xaml.h @@ -64,6 +64,7 @@ private: void _toggleSmartBoxButton__Click(Platform::Object^ sender, Windows::UI::Xaml::RoutedEventArgs^ e); void showFrame(Windows::UI::Xaml::Controls::Frame^ frame); void OnsummonMessageTextPage(); + void OnToggleFullScreen(bool state); void OnsummonWelcomePage(); void OnsummonPreviewPage(); void OnhidePreviewPage(); diff --git a/Package.appxmanifest b/Package.appxmanifest index 71f87a49ce60b5cb78c55d895db591f317c849c7..5eb7a74cf228064b215fe92e94e0af37f4641e65 100644 --- a/Package.appxmanifest +++ b/Package.appxmanifest @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> <Package xmlns="http://schemas.microsoft.com/appx/manifest/foundation/windows10" xmlns:mp="http://schemas.microsoft.com/appx/2014/phone/manifest" xmlns:uap="http://schemas.microsoft.com/appx/manifest/uap/windows10" xmlns:uap3="http://schemas.microsoft.com/appx/manifest/uap/windows10/3" IgnorableNamespaces="uap uap3 mp"> - <Identity Name="Savoir-faireLinux.GNURing" Publisher="CN=8121A5F7-3CA1-4CAA-92B2-4F595B011941" Version="1.1.21.0" /> + <Identity Name="Savoir-faireLinux.GNURing" Publisher="CN=8121A5F7-3CA1-4CAA-92B2-4F595B011941" Version="1.1.62.0" /> <mp:PhoneIdentity PhoneProductId="2385953f-9019-423d-aa82-d1bbacfa258b" PhonePublisherId="00000000-0000-0000-0000-000000000000" /> <Properties> <DisplayName>GNU Ring</DisplayName> diff --git a/RingD.cpp b/RingD.cpp index f3e8c05cde1e1af3c6d8e0cfcb1303d3730e0eca..a037a046c8a07c2dda0b586772bcebba98dd005e 100644 --- a/RingD.cpp +++ b/RingD.cpp @@ -47,14 +47,13 @@ using namespace RingClientUWP; using namespace RingClientUWP::Utils; using namespace RingClientUWP::ViewModel; +using namespace Windows::UI::ViewManagement; using namespace Windows::System; void RingClientUWP::RingD::reloadAccountList() { - //RingClientUWP::ViewModel::AccountsViewModel::instance->clearAccountList(); - std::vector<std::string> accountList = DRing::getAccountList(); /* if for any reason there is no account at all, screen the wizard */ @@ -593,13 +592,13 @@ RingD::registerCallbacks() static const unsigned int profileSize = VCardUtils::PROFILE_VCF.size(); for (auto i : payloads) { + MSG_(i.first); if (i.first.compare(0, profileSize, VCardUtils::PROFILE_VCF) == 0) { MSG_("payload.first = " + i.first); MSG_("payload.second = " + i.second); int res = contact->getVCard()->receiveChunk(i.first, i.second); return; } - auto payload = Utils::toPlatformString(i.second); CoreApplication::MainView->CoreWindow->Dispatcher->RunAsync( CoreDispatcherPriority::High, ref new DispatchedHandler([=]() @@ -1343,7 +1342,6 @@ RingClientUWP::CallStatus RingClientUWP::RingD::translateCallStatus(String^ stat if (state == "PEER_PAUSED") return CallStatus::PEER_PAUSED; - return CallStatus::NONE; } @@ -1367,3 +1365,22 @@ Vector<String^>^ RingClientUWP::RingD::translateKnownRingDevices(const std::map< return devicesList; } + +void RingClientUWP::RingD::raiseToggleFullScreen() +{ + ApplicationView^ view = ApplicationView::GetForCurrentView(); + if (view->IsFullScreenMode) { + view->ExitFullScreenMode(); + toggleFullScreen(false); + MSG_("Successfully exited fullscreen"); + } + else { + if (view->TryEnterFullScreenMode()) { + MSG_("Successfully entered fullscreen"); + toggleFullScreen(true); + } + else { + ERR_("Unsuccessfully entered fullscreen"); + } + } +} diff --git a/RingD.h b/RingD.h index 822ec25a403bb789cc87aeaba18c3b5079c29b59..c31bbd969d4504fe2dc73f8f7cfb7de40e609f11 100644 --- a/RingD.h +++ b/RingD.h @@ -54,6 +54,7 @@ delegate void CallsListRecieved(const std::vector<std::string>& callsList); delegate void AudioMuted(const std::string& callId, bool state); delegate void VideoMuted(const std::string& callId, bool state); delegate void NameRegistred(bool status); +delegate void ToggleFullScreen(bool state); delegate void VolatileDetailsChanged(const std::string& accountId, const std::map<std::string, std::string>& details); using SharedCallback = std::shared_ptr<DRing::CallbackWrapperBase>; @@ -139,6 +140,8 @@ internal: String^ getUserName(); Vector<String^>^ translateKnownRingDevices(const std::map<std::string, std::string> devices); + void raiseToggleFullScreen(); + void hangUpCall2(String^ callId); void pauseCall(String ^ callId); void unPauseCall(String ^ callId); @@ -183,6 +186,7 @@ internal: event AudioMuted^ audioMuted; event VideoMuted^ videoMuted; event NameRegistred^ nameRegistred; + event ToggleFullScreen^ toggleFullScreen; event VolatileDetailsChanged^ volatileDetailsChanged; private: diff --git a/VideoCaptureManager.cpp b/VideoCaptureManager.cpp index e8202276c53be1c12ddb5440ef46bb10a43af2a4..26ccbc27c4206e31d52e4da1044e4ef84d67c69d 100644 --- a/VideoCaptureManager.cpp +++ b/VideoCaptureManager.cpp @@ -60,7 +60,7 @@ VideoCaptureManager::VideoCaptureManager(): }) { deviceList = ref new Vector<Device^>(); - InitializeCopyFrameDispatcher(30); + InitializeCopyFrameDispatcher(60); captureTaskTokenSource = new cancellation_token_source(); } diff --git a/VideoPage.xaml b/VideoPage.xaml index 7fee9c175ae4505f7f24bcdb50f4c2cc6e7bb2fb..57672003643974d63460d098fb90c512f7b96b84 100644 --- a/VideoPage.xaml +++ b/VideoPage.xaml @@ -174,7 +174,9 @@ <!-- video --> <Image Name="IncomingVideoImage" Grid.Column="0" - Canvas.ZIndex="-1"/> + Canvas.ZIndex="-1" + DoubleTapped="IncomingVideoImage_DoubleTapped" + /> <TextBlock Name="_callPaused_" Grid.Column="0" Text="" diff --git a/VideoPage.xaml.cpp b/VideoPage.xaml.cpp index d513ebc7c516e7ec8e508db4fe47dd3e238b1533..d8842a0089b6e1710549d5766b1beed1ce3356bf 100644 --- a/VideoPage.xaml.cpp +++ b/VideoPage.xaml.cpp @@ -135,12 +135,17 @@ VideoPage::VideoPage() break; } case CallStatus::ENDED: + { Video::VideoManager::instance->rendererManager()->raiseClearRenderTarget(); + if (Windows::UI::ViewManagement::ApplicationView::GetForCurrentView()->IsFullScreen) + RingD::instance->raiseToggleFullScreen(); + /* "close" the chat panel */ _rowChatBx_->Height = 0; break; + } case CallStatus::PEER_PAUSED: case CallStatus::PAUSED: _callPaused_->Visibility = Windows::UI::Xaml::Visibility::Visible; @@ -449,3 +454,9 @@ void RingClientUWP::Views::VideoPage::OnvideoMuted(const std::string &callId, bo _txbkVideoMuted_->Visibility = (state) ? Windows::UI::Xaml::Visibility::Visible : Windows::UI::Xaml::Visibility::Collapsed; } + + +void RingClientUWP::Views::VideoPage::IncomingVideoImage_DoubleTapped(Platform::Object^ sender, Windows::UI::Xaml::Input::DoubleTappedRoutedEventArgs^ e) +{ + RingD::instance->raiseToggleFullScreen(); +} \ No newline at end of file diff --git a/VideoPage.xaml.h b/VideoPage.xaml.h index bda71fa12a6f9c021bae8c84d1f9d96cff017626..e7b5a7d960f78f80e097dc42fe7f5bc84a3f5bea 100644 --- a/VideoPage.xaml.h +++ b/VideoPage.xaml.h @@ -112,6 +112,7 @@ private: void _btnMicrophone__Click(Platform::Object^ sender, Windows::UI::Xaml::RoutedEventArgs^ e); void OnaudioMuted(const std::string &callId, bool state); void OnvideoMuted(const std::string &callId, bool state); + void IncomingVideoImage_DoubleTapped(Platform::Object^ sender, Windows::UI::Xaml::Input::DoubleTappedRoutedEventArgs^ e); }; } } \ No newline at end of file diff --git a/_language-fr.appx b/_language-fr.appx index d8862e0c6b2750b7d59f8d65a167c0f599205e9b..51bf9e26b8f25bb43d7a7124c7fb5a83661df0cf 100644 Binary files a/_language-fr.appx and b/_language-fr.appx differ diff --git a/_scale-100.appx b/_scale-100.appx index d9d035bb4a0ad11a84111b5b051a2913f146d790..cba6a7476ff3db03c797713c7ccb125cb18aa794 100644 Binary files a/_scale-100.appx and b/_scale-100.appx differ diff --git a/_scale-125.appx b/_scale-125.appx index 737754afb6d516df606e93c06bbea5be4e17e888..6d6ece8d6416fbfc5965c62c9718bdc4b0b5df56 100644 Binary files a/_scale-125.appx and b/_scale-125.appx differ diff --git a/_scale-150.appx b/_scale-150.appx index 6e1aadb2df081e41fece15ae42fc0fbde1a714a0..09b8ffe25c8097d08c7be5a57bdcaef446b705df 100644 Binary files a/_scale-150.appx and b/_scale-150.appx differ diff --git a/_scale-400.appx b/_scale-400.appx index 5520c2dfad3032df08761715bad34d06276778d5..698e354d015f8f98033b918534b6e2417564952d 100644 Binary files a/_scale-400.appx and b/_scale-400.appx differ diff --git a/contrib/qrencode-win32/vc8/qrcodelib/qrcodelib.vcxproj b/contrib/qrencode-win32/vc8/qrcodelib/qrcodelib.vcxproj index 16d97a3c87f07ee8ba6a7f54310b679c00e6afda..0a088e20c6d832b3af92fd7a62740161957cc0ab 100644 --- a/contrib/qrencode-win32/vc8/qrcodelib/qrcodelib.vcxproj +++ b/contrib/qrencode-win32/vc8/qrcodelib/qrcodelib.vcxproj @@ -38,6 +38,7 @@ <ProjectGuid>{9A90BF5C-84B0-41F6-B83C-C20EADC1F46C}</ProjectGuid> <RootNamespace>qrcodelib</RootNamespace> <Keyword>Win32Proj</Keyword> + <WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion> </PropertyGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release-Lib|Win32'" Label="Configuration"> @@ -139,6 +140,9 @@ <OutDir>../.build/$(Configuration)\</OutDir> <IntDir>../.build/$(ProjectName)/$(Configuration)\</IntDir> </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release-Lib|x64'"> + <OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir> + </PropertyGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug-Dll|Win32'"> <ClCompile> <Optimization>Disabled</Optimization> diff --git a/ring-client-uwp.sln b/ring-client-uwp.sln index ee99289f9a7ea061a05935f2810d5797406c18d0..c6a0c18dd03071b1bbab9cadb12cd8df32df9a3c 100644 --- a/ring-client-uwp.sln +++ b/ring-client-uwp.sln @@ -9,9 +9,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ring-client-uwp", "ring-cli EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ring-daemon", "..\ring-daemon\MSVC\ring-daemon.vcxproj", "{79F8DE42-595D-49D9-A66F-55244FD9DCC3}" - ProjectSection(ProjectDependencies) = postProject - {6BD59A09-0768-40D3-A04B-10F95555689B} = {6BD59A09-0768-40D3-A04B-10F95555689B} - EndProjectSection EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "contrib daemon", "contrib daemon", "{96846C59-E0A1-4132-B779-065C2EAE3E51}" EndProject diff --git a/ring-client-uwp.vcxproj b/ring-client-uwp.vcxproj index 83baac45ab21db677d720ee3e9082b00e4ef0b4a..42a0f6379f245d7d0ca7602f481e0b9967896645 100644 --- a/ring-client-uwp.vcxproj +++ b/ring-client-uwp.vcxproj @@ -147,7 +147,7 @@ <CompileAsWinRT>true</CompileAsWinRT> </ClCompile> <Link> - <AdditionalLibraryDirectories>$(SolutionDir)..\ring-daemon\contrib\build\boost\stage\lib;$(SolutionDir)..\ring-daemon\contrib\build\bin\x64;$(SolutionDir)..\ring-daemon\contrib\build\lib\x64;$(SolutionDir)..\ring-daemon\MSVC\x64\ReleaseLib\bin;$(SolutionDir)x64\Release-Lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories> + <AdditionalLibraryDirectories>$(SolutionDir)..\ring-daemon\contrib\build\boost\stage\lib;$(SolutionDir)..\ring-daemon\contrib\build\bin\x64;$(SolutionDir)..\ring-daemon\contrib\build\lib\x64;$(SolutionDir)..\ring-daemon\MSVC\x64\ReleaseLib\bin;$(SolutionDir)x64\Release-Lib;$(SolutionDir)contrib\qrencode-win32\vc8\qrcodelib\x64\Release-Lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories> </Link> <ProjectReference> <LinkLibraryDependencies>false</LinkLibraryDependencies> @@ -267,6 +267,9 @@ <None Include="..\ring-daemon\contrib\build\FFmpegInterop\ffmpeg\Build\Windows10\x64\bin\avutil-55.dll"> <DeploymentContent>true</DeploymentContent> </None> + <None Include="..\ring-daemon\contrib\build\FFmpegInterop\ffmpeg\Build\Windows10\x64\bin\postproc-54.dll"> + <DeploymentContent Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</DeploymentContent> + </None> <None Include="..\ring-daemon\contrib\build\FFmpegInterop\ffmpeg\Build\Windows10\x64\bin\swresample-2.dll"> <DeploymentContent>true</DeploymentContent> </None> diff --git a/ring-client-uwp.vcxproj.filters b/ring-client-uwp.vcxproj.filters index 72bc9b14afddd580cdbeba15e89d5d10e0cf92b8..6495567bf5f9dcf2f0479d6e8e3060b26ca4c943 100644 --- a/ring-client-uwp.vcxproj.filters +++ b/ring-client-uwp.vcxproj.filters @@ -250,6 +250,9 @@ <None Include="..\ring-daemon\contrib\build\FFmpegInterop\ffmpeg\Build\Windows10\x64\bin\swscale-4.dll"> <Filter>Assets\Dlls</Filter> </None> + <None Include="..\ring-daemon\contrib\build\FFmpegInterop\ffmpeg\Build\Windows10\x64\bin\postproc-54.dll"> + <Filter>Assets\Dlls</Filter> + </None> <None Include="..\ring-daemon\contrib\build\restbed\dependency\openssl\out32dll\libeay32.dll"> <Filter>Assets\Dlls</Filter> </None>