Commit b23fe1d8 authored by Sylvain Berfini's avatar Sylvain Berfini 🎩

Fix GetCallLogs stub

parent 25126307
......@@ -64,16 +64,13 @@ Platform::String^ LinphoneAddress::ToString()
}
LinphoneAddress::LinphoneAddress(Platform::String^ address) :
address(address),
displayName(nullptr),
username(nullptr),
domain(nullptr)
address(address)
{
}
LinphoneAddress::LinphoneAddress(Platform::String^ username, Platform::String^ domain, Platform::String^ displayName) :
address("sip:" + username + "@" + domain),
address(L"sip:" + username + "@" + domain),
displayName(displayName),
username(username),
domain(domain)
......
......@@ -30,17 +30,17 @@ namespace Linphone
/// Human display name
/// </summary>
/// <returns>
/// null if not set
/// an empty string if not set
/// </returns>
Platform::String^ GetDisplayName();
/// <returns>
/// null if not set
/// an empty string if not set
/// </returns>
Platform::String^ GetUserName();
/// <returns>
/// null if not set
/// an empty string if not set
/// </returns>
Platform::String^ GetDomain();
......
......@@ -239,7 +239,7 @@ IVector<Object^>^ LinphoneCore::GetCallLogs()
IVector<Object^>^ logs = ref new Vector<Object^>();
LinphoneCallLog^ log = ref new LinphoneCallLog(L"sip:miaou@sip.linphone.org", L"sip:waouf@sip.linphone.org", LinphoneCallStatus::Missed, CallDirection::Incoming);
LinphoneCallLog^ log = ref new LinphoneCallLog(L"sip:waouf@sip.linphone.org", L"sip:miaou@sip.linphone.org", LinphoneCallStatus::Missed, CallDirection::Incoming);
logs->Append(log);
log = ref new LinphoneCallLog(L"sip:waouf@sip.linphone.org", L"sip:miaou@sip.linphone.org", LinphoneCallStatus::Success, CallDirection::Outgoing);
logs->Append(log);
......
......@@ -415,6 +415,7 @@ namespace Linphone
LinphoneCoreListener^ listener;
LinphoneCall^ call;
LinphoneCall^ incomingcall;
bool callAccepted;
bool callEnded;
bool callConnected;
......
No preview for this file type
......@@ -241,11 +241,11 @@ namespace Linphone.Model
foreach (LinphoneCallLog log in LinphoneCore.GetCallLogs())
{
string from = log.GetFrom().GetDisplayName();
if (from == null)
if (from.Length == 0)
from = log.GetFrom().AsStringUriOnly();
string to = log.GetTo().GetDisplayName();
if (to == null)
if (to.Length == 0)
to = log.GetTo().AsStringUriOnly();
bool isMissed = log.GetStatus() == LinphoneCallStatus.Missed;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment