Merge master into feature/GraphingCalculator branch (#660)

This commit is contained in:
Pepe Rivera 2019-09-05 15:01:12 -07:00 коммит произвёл GitHub
Родитель 1c9755d38a
Коммит 41fbcfe9c5
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
199 изменённых файлов: 5809 добавлений и 2925 удалений

Просмотреть файл

@ -38,6 +38,9 @@ Prerequisites:
- Open [src\Calculator.sln](/src/Calculator.sln) in Visual Studio to build and run the Calculator app.
- For a general description of the Calculator project architecture see [ApplicationArchitecture.md](docs/ApplicationArchitecture.md).
- To run the UI Tests, you need to make sure that
[Windows Application Driver (WinAppDriver)](https://github.com/microsoft/WinAppDriver/releases/latest)
is installed.
## Contributing
Want to contribute? The team encourages community feedback and contributions. Please follow our [contributing guidelines](CONTRIBUTING.md).
@ -52,25 +55,20 @@ For information regarding Windows Calculator plans and release schedule, please
Adding graphing calculator functionality [is on the project roadmap](https://github.com/Microsoft/calculator/issues/338) and we hope that this project can create a great end-user experience around graphing. To that end, the UI from the official in-box Windows Calculator is currently part of this repository, although the proprietary Microsoft-built graphing engine, which also drives graphing in Microsoft Mathematics and OneNote, is not. Community members can still be involved in the creation of the UI, however developer builds will not have graphing functionality due to the use of a [mock implementation of the engine](/src/MockGraphingImpl) built on top of a
[common graphing API](/src/GraphingInterfaces).
## Data / Telemetry
## Diagnostic Data
This project collects usage data and sends it to Microsoft to help improve our products and services.
Read our [privacy statement](https://go.microsoft.com/fwlink/?LinkId=521839) to learn more.
Telemetry is disabled in development builds by default, and can be enabled with the `SEND_TELEMETRY`
Diagnostic data is disabled in development builds by default, and can be enabled with the `SEND_DIAGNOSTICS`
build flag.
## Currency Converter
Windows Calculator includes a currency converter feature that uses mock data in developer builds. The data that
Microsoft uses for the currency converter feature (e.g., in the retail version of the application) is not licensed
for your use. The mock data will be clearly identifiable as it references planets instead of countries,
Windows Calculator includes a currency converter feature that uses mock data in developer builds. The data that
Microsoft uses for the currency converter feature (e.g., in the retail version of the application) is not licensed
for your use. The mock data will be clearly identifiable as it references planets instead of countries,
and remains static regardless of selected inputs.
## Reporting Security Issues
Security issues and bugs should be reported privately, via email, to the
Microsoft Security Response Center (MSRC) at <[secure@microsoft.com](mailto:secure@microsoft.com)>.
You should receive a response within 24 hours. If for some reason you do not, please follow up via
email to ensure we received your original message. Further information, including the
[MSRC PGP](https://technet.microsoft.com/en-us/security/dn606155) key, can be found in the
[Security TechCenter](https://technet.microsoft.com/en-us/security/default).
Please refer to [SECURITY.md](./SECURITY.md).
## License
Copyright (c) Microsoft Corporation. All rights reserved.

48
SECURITY.md Normal file
Просмотреть файл

@ -0,0 +1,48 @@
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.1 BLOCK -->
## Security
Microsoft takes the security of our software products and services seriously, which includes all
source code repositories managed through our GitHub organizations, which include
[Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure),
[DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet),
[Xamarin](https://github.com/xamarin), and [many more](https://opensource.microsoft.com/).
If you believe you have found a security vulnerability in any Microsoft-owned repository that meets
Microsoft's [definition](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10))
of a security vulnerability, please report it to us as described below.
## Reporting Security Issues
**Please do not report security vulnerabilities through public GitHub issues.** Instead, please
report them to the Microsoft Security Response Center at [secure@microsoft.com](mailto:secure@microsoft.com).
If possible, encrypt your message with our PGP key; please download it from the
[Microsoft Security Response Center PGP Key page](https://technet.microsoft.com/en-us/security/dn606155).
You should receive a response within 24 hours. If for some reason you do not, please follow up via
email to ensure we received your original message. Additional information can be found at
[microsoft.com/msrc](https://www.microsoft.com/msrc).
Please include the requested information listed below (as much as you can provide) to help us better
understand the nature and scope of the possible issue:
* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
* Full paths of source file(s) related to the manifestation of the issue
* The location of the affected source code (tag/branch/commit or direct URL)
* Any special configuration required to reproduce the issue
* Step-by-step instructions to reproduce the issue
* Proof-of-concept or exploit code (if possible)
* Impact of the issue, including how an attacker might exploit the issue
This information will help us triage your report more quickly.
## Preferred Languages
We prefer all communications to be in English.
## Policy
Microsoft follows the principle of
[Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).
<!-- END MICROSOFT SECURITY.MD BLOCK -->

Просмотреть файл

@ -9,8 +9,8 @@ pr: none
variables:
versionMajor: 10
versionMinor: 1906
versionBuild: $[counter('10.1906.*', 0)]
versionMinor: 1907
versionBuild: $[counter('10.1907.*', 0)]
versionPatch: 0
name: '$(versionMajor).$(versionMinor).$(versionBuild).$(versionPatch)'

Просмотреть файл

@ -29,7 +29,7 @@ jobs:
downloadDirectory: $(Build.SourcesDirectory)
vstsFeed: WindowsApps
vstsFeedPackage: calculator-internals
vstsPackageVersion: 0.0.11
vstsPackageVersion: 0.0.18
- template: ./build-single-architecture.yaml
parameters:

Просмотреть файл

@ -38,10 +38,13 @@ jobs:
filePath: $(Build.SourcesDirectory)\build\scripts\CreateAppxBundleMapping.ps1
arguments: '-InputPath $(Build.ArtifactStagingDirectory)\drop\Release -ProjectName Calculator -OutputFile $(Build.BinariesDirectory)\AppxBundleMapping.txt'
- script: '"C:\Program Files (x86)\Windows Kits\10\bin\10.0.17763.0\x86\MakeAppx.exe" bundle /v /bv %BUNDLEVERSION% /f %MAPPINGFILEPATH% /p %OUTPUTPATH%'
- powershell: |
$buildVersion = [version]$Env:BUILDVERSION
$bundleVersion = "2020.$($buildVersion.Minor).$($buildVersion.Build).$($buildVersion.Revision)"
& "C:\Program Files (x86)\Windows Kits\10\bin\10.0.18362.0\x86\MakeAppx.exe" bundle /v /bv $bundleVersion /f $Env:MAPPINGFILEPATH /p $Env:OUTPUTPATH
displayName: Make AppxBundle
env:
BUNDLEVERSION: $(Build.BuildNumber)
BUILDVERSION: $(Build.BuildNumber)
MAPPINGFILEPATH: $(Build.BinariesDirectory)\AppxBundleMapping.txt
OUTPUTPATH: $(Build.BinariesDirectory)\Microsoft.WindowsCalculator_8wekyb3d8bbwe.appxbundle

Просмотреть файл

@ -91,7 +91,7 @@ jobs:
downloadDirectory: $(Build.SourcesDirectory)
vstsFeed: WindowsApps
vstsFeedPackage: calculator-internals
vstsPackageVersion: 0.0.11
vstsPackageVersion: 0.0.18
- task: PkgESStoreBrokerPackage@10
displayName: Create StoreBroker Packages

Просмотреть файл

@ -54,6 +54,59 @@ Steps:
2. Select “miles” as the unit type in the output field
*Expected: The output starts with is “3.106856”*
### Always-on-Top
**Test 1**
Steps:
1. Launch the "Calculator" app and navigate to "Standard" Calculator
*Expected: Always-on-Top button's tooltip says "Keep on top"*
2. Click the Always-on-Top button
*Expected: Always-on-Top button's tooltip now says "Back to full view"*
3. Launch the "Notepad" app and put it in full-screen mode
*Expected: Calculator is still on top of Notepad and in Always-on-Top mode*
**Test 2**
Steps:
1. Launch the "Calculator" app and from "Standard" Calculator, input “3”, “+”, “3” (do not press “Enter”)
2. Tab over the Always-on-Top button and press "Enter" on the keyboard
*Expected: The application title, hamburger menu, calculator type title, calculation expression (the secondary line above the main display), history button and memory buttons are no longer visible. The main display shows "3"*
2. Press “Enter”
*Expected: The main display shows "6"*
3. Press "Ctrl-H" on the keyboard
*Expected: Nothing happens (history keyboard shortcuts are disabled)*
4. Press "Ctrl-P" on the keyboard, then tab over the Always-on-Top button and press "Enter" on the keyboard again
5. Open the Memory panel
*Expected: Nothing is stored in memory (memory keyboard shortcuts are disabled in Always-on-Top mode) and "6" is in history*
**Test 3**
Steps:
1. Launch the "Calculator" app and from "Standard" Calculator, click the Always-on-Top button
2. Resize the window horizontally
*Expected: The buttons automatically expand or shrink to fit the available screen size*
3. Resize the window vertically
*Expected: The buttons automatically expand or shrink to fit the available screen size and the percent, square-root, squared and reciprocal buttons disappear when the screen height is small*
4. Click the Always-on-Top button again
*Expected: Calculator is in Standard mode and the original window layout from before Step 1 is restored*
5. Click the Always-on-Top button again
*Expected: Calculator is in Always-on-Top mode and the window size from after Step 3 is restored*
6. Close the "Calculator" app
7. Launch the "Calculator" app again and click the Always-on-Top button
*Expected: The window size from right before closing from Always-on-Top mode (ie. after Step 5) is restored*
**Test 4**
Steps:
1. Launch the "Calculator" app and from "Standard" Calculator, click the Always-on-Top button
2. Input "/", "0", “Enter” on the keyboard
*Expected: "Result is undefined" is displayed in the system default app language*
3. Click the Always-on-Top button again
*Expected: Calculator is in Standard mode and all operator (except for "CE", "C", "Delete" and "=") and memory buttons are disabled
**Test 5**
Steps:
1. Launch the "Calculator" app and navigate to "Scientific" Calculator
*Expected: The Always-on-Top button is hidden*
2. Navigate to "Standard" Calculator
*Expected: The Always-on-Top button is visible*
## Basic Verification Tests
@ -278,7 +331,7 @@ Steps:
Steps:
1. Launch the "Calculator" app.
For All Applicable Modes verify the following:
For All Applicable Modes verify the following (note: only 11-15 and 20 work in Always-on-Top mode):
2. Press **Alt +1** to Enter "Standard" mode
*Expected: Move to "Standard" screen.*
3. Press **Alt +2** to Enter "Scientific" mode
@ -353,3 +406,30 @@ Steps:
61. Press **|** to Select 'Or'
62. Press **~** to Select 'Not'
63. Press **&** to Select 'And'
## Localization Tests
### Always-on-Top
**Test 1**
Steps:
1. Change the system default app language to Arabic
2. Launch the "Calculator" app and from "Standard" Calculator, click the Always-on-Top button
*Expected: UI/Menu is localized (for example, the title bar buttons is in right-to-left order)*
3. Input "/", "0", “Enter” on the keyboard
*Expected: Error message is in Arabic*
## Ease of Access Tests
### Always-on-Top
**Test 1**
Steps:
1. Open the "Narrator" app
2. Launch the "Calculator" app and from "Standard" Calculator, click the Always-on-Top button
3. Tab over the Always-on-Top button
*Expected: Narrator reads the localized version of "Back to full view"*
4. Tab over the main results field
*Expected: Narrator reads the localized version of exactly what's displayed (ie. "0")*
5. Tab over the rest of the UI elements
*Expected: Narrator reads the localized version of the UI elements' contents*

Просмотреть файл

@ -951,7 +951,7 @@ int CCalcEngine::GetCurrentRadix()
return m_radix;
}
wstring CCalcEngine::GetCurrentResultForRadix(uint32_t radix, int32_t precision)
wstring CCalcEngine::GetCurrentResultForRadix(uint32_t radix, int32_t precision, bool groupDigitsPerRadix)
{
Rational rat = (m_bRecord ? m_input.ToRational(m_radix, m_precision) : m_currentVal);
@ -964,7 +964,14 @@ wstring CCalcEngine::GetCurrentResultForRadix(uint32_t radix, int32_t precision)
ChangeConstants(m_radix, m_precision);
}
return GroupDigitsPerRadix(numberString, radix);
if (groupDigitsPerRadix)
{
return GroupDigitsPerRadix(numberString, radix);
}
else
{
return numberString;
}
}
wstring CCalcEngine::GetStringForDisplay(Rational const& rat, uint32_t radix)

Просмотреть файл

@ -45,8 +45,8 @@
<AppContainerApplication>true</AppContainerApplication>
<ApplicationType>Windows Store</ApplicationType>
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>
<WindowsTargetPlatformVersion Condition="'$(WindowsTargetPlatformVersion)' == ''">10.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion>10.0.18362.0</WindowsTargetPlatformMinVersion>
<WindowsTargetPlatformVersion Condition="'$(WindowsTargetPlatformVersion)' == ''">10.0.18362.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion>10.0.17134.0</WindowsTargetPlatformMinVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<!-- This has to be exactly in this place for this to work -->
@ -309,6 +309,7 @@
<ClInclude Include="Ratpack\CalcErr.h" />
<ClInclude Include="Ratpack\ratconst.h" />
<ClInclude Include="Ratpack\ratpak.h" />
<ClInclude Include="NumberFormattingUtils.h" />
<ClInclude Include="UnitConverter.h" />
</ItemGroup>
<ItemGroup>
@ -349,6 +350,7 @@
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
</ClCompile>
<ClCompile Include="NumberFormattingUtils.cpp" />
<ClCompile Include="UnitConverter.cpp" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />

Просмотреть файл

@ -89,6 +89,7 @@
<ClCompile Include="CEngine\RationalMath.cpp">
<Filter>CEngine</Filter>
</ClCompile>
<ClCompile Include="NumberFormattingUtils.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="Command.h" />
@ -160,5 +161,6 @@
<ClInclude Include="Header Files\RationalMath.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="NumberFormattingUtils.h" />
</ItemGroup>
</Project>
</Project>

Просмотреть файл

@ -37,15 +37,6 @@ namespace CalculationManager
CCalcEngine::InitialOneTimeOnlySetup(*m_resourceProvider);
}
/// <summary>
/// Destructor for CalculatorManager
/// Ends two CCalcEngine
/// </summary>
CalculatorManager::~CalculatorManager()
{
this->MemorizedNumberClearAll();
}
/// <summary>
/// Call the callback function using passed in IDisplayHelper.
/// Used to set the primary display value on ViewModel
@ -622,9 +613,9 @@ namespace CalculationManager
}
}
wstring CalculatorManager::GetResultForRadix(uint32_t radix, int32_t precision)
wstring CalculatorManager::GetResultForRadix(uint32_t radix, int32_t precision, bool groupDigitsPerRadix)
{
return m_currentCalculatorEngine ? m_currentCalculatorEngine->GetCurrentResultForRadix(radix, precision) : L"";
return m_currentCalculatorEngine ? m_currentCalculatorEngine->GetCurrentResultForRadix(radix, precision, groupDigitsPerRadix) : L"";
}
void CalculatorManager::SetPrecision(int32_t precision)

Просмотреть файл

@ -103,7 +103,6 @@ namespace CalculationManager
void MemoryItemChanged(unsigned int indexOfMemory) override;
CalculatorManager(ICalcDisplay* displayCallback, IResourceProvider* resourceProvider);
~CalculatorManager();
void Reset(bool clearMemory = true);
void SetStandardMode();
@ -125,7 +124,7 @@ namespace CalculationManager
}
void SetRadix(RADIX_TYPE iRadixType);
void SetMemorizedNumbersString();
std::wstring GetResultForRadix(uint32_t radix, int32_t precision);
std::wstring GetResultForRadix(uint32_t radix, int32_t precision, bool groupDigitsPerRadix);
void SetPrecision(int32_t precision);
void UpdateMaxIntDigits();
wchar_t DecimalSeparator();

Просмотреть файл

@ -137,6 +137,7 @@ void COpndCommand::AppendCommand(int command)
{
m_commands->Append(command);
}
if (command == IDC_PNT)
{
m_fDecimal = true;
@ -256,38 +257,30 @@ const wstring& COpndCommand::GetToken(wchar_t decimalSymbol)
}
// Remove zeros
bool fDigitsFound = false;
int trimIdx = 0;
for (unsigned int i = 0; i < m_token.size(); i++)
{
if (m_token.at(i) != chZero)
{
if (m_token.at(i) == decimalSymbol)
{
trimIdx = i - 1;
m_token.erase(0, i - 1);
}
else
{
trimIdx = i;
m_token.erase(0, i);
}
fDigitsFound = true;
break;
if (m_fNegative)
{
m_token.insert(0, &chNegate);
}
return m_token;
}
}
if (fDigitsFound)
{
m_token.erase(0, trimIdx);
if (m_fNegative)
{
m_token.insert(0, &chNegate);
}
}
else
{
m_token.clear();
m_token.append(&chZero);
}
m_token.clear();
m_token.append(&chZero);
return m_token;
}

Просмотреть файл

@ -75,7 +75,7 @@ public:
void SettingsChanged();
bool IsCurrentTooBigForTrig();
int GetCurrentRadix();
std::wstring GetCurrentResultForRadix(uint32_t radix, int32_t precision);
std::wstring GetCurrentResultForRadix(uint32_t radix, int32_t precision, bool groupDigitsPerRadix);
void ChangePrecision(int32_t precision)
{
m_precision = precision;

Просмотреть файл

@ -0,0 +1,84 @@
#include "pch.h"
#include "NumberFormattingUtils.h"
using namespace std;
namespace CalcManager::NumberFormattingUtils
{
/// <summary>
/// Trims out any trailing zeros or decimals in the given input string
/// </summary>
/// <param name="number">number to trim</param>
void TrimTrailingZeros(_Inout_ wstring& number)
{
if (number.find(L'.') == wstring::npos)
{
return;
}
wstring::iterator iter;
for (iter = number.end() - 1;; iter--)
{
if (*iter != L'0')
{
number.erase(iter + 1, number.end());
break;
}
}
if (*(number.end() - 1) == L'.')
{
number.erase(number.end() - 1, number.end());
}
}
/// <summary>
/// Get number of digits (whole number part + decimal part)</summary>
/// <param name="value">the number</param>
unsigned int GetNumberDigits(wstring value)
{
TrimTrailingZeros(value);
unsigned int numberSignificantDigits = static_cast<unsigned int>(value.size());
if (value.find(L'.') != wstring::npos)
{
--numberSignificantDigits;
}
if (value.find(L'-') != wstring::npos)
{
--numberSignificantDigits;
}
return numberSignificantDigits;
}
/// <summary>
/// Get number of digits (whole number part only)</summary>
/// <param name="value">the number</param>
unsigned int GetNumberDigitsWholeNumberPart(double value)
{
return value == 0 ? 1 : (1 + (int)log10(abs(value)));
}
/// <summary>
/// Rounds the given double to the given number of significant digits
/// </summary>
/// <param name="num">input double</param>
/// <param name="numSignificant">int number of significant digits to round to</param>
wstring RoundSignificantDigits(double num, int numSignificant)
{
wstringstream out(wstringstream::out);
out << fixed;
out.precision(numSignificant);
out << num;
return out.str();
}
/// <summary>
/// Convert a Number to Scientific Notation
/// </summary>
/// <param name="number">number to convert</param>
wstring ToScientificNumber(double number)
{
wstringstream out(wstringstream::out);
out << scientific << number;
return out.str();
}
}

Просмотреть файл

@ -0,0 +1,15 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#pragma once
#include <string>
namespace CalcManager::NumberFormattingUtils
{
void TrimTrailingZeros(_Inout_ std::wstring& input);
unsigned int GetNumberDigits(std::wstring value);
unsigned int GetNumberDigitsWholeNumberPart(double value);
std::wstring RoundSignificantDigits(double value, int numberSignificantDigits);
std::wstring ToScientificNumber(double number);
}

Просмотреть файл

@ -7,9 +7,11 @@
#include <algorithm> // for std::sort
#include "Command.h"
#include "UnitConverter.h"
#include "NumberFormattingUtils.h"
using namespace std;
using namespace UnitConversionManager;
using namespace CalcManager::NumberFormattingUtils;
static constexpr uint32_t EXPECTEDSERIALIZEDCATEGORYTOKENCOUNT = 3;
static constexpr uint32_t EXPECTEDSERIALIZEDUNITTOKENCOUNT = 6;
@ -178,7 +180,7 @@ void UnitConverter::SwitchActive(const wstring& newValue)
swap(m_currentHasDecimal, m_returnHasDecimal);
m_returnDisplay = m_currentDisplay;
m_currentDisplay = newValue;
m_currentHasDecimal = (m_currentDisplay.find(L'.') != m_currentDisplay.npos);
m_currentHasDecimal = (m_currentDisplay.find(L'.') != wstring::npos);
m_switchedActive = true;
if (m_currencyDataLoader != nullptr && m_vmCurrencyCallback != nullptr)
@ -202,7 +204,7 @@ vector<wstring> UnitConverter::StringToVector(const wstring& w, const wchar_t* d
size_t delimiterIndex = w.find(delimiter);
size_t startIndex = 0;
vector<wstring> serializedTokens = vector<wstring>();
while (delimiterIndex != w.npos)
while (delimiterIndex != wstring::npos)
{
serializedTokens.push_back(w.substr(startIndex, delimiterIndex - startIndex));
startIndex = delimiterIndex + (int)wcslen(delimiter);
@ -634,19 +636,19 @@ vector<tuple<wstring, Unit>> UnitConverter::CalculateSuggested()
wstring roundedString;
if (abs(entry.value) < 100)
{
roundedString = RoundSignificant(entry.value, 2);
roundedString = RoundSignificantDigits(entry.value, 2);
}
else if (abs(entry.value) < 1000)
{
roundedString = RoundSignificant(entry.value, 1);
roundedString = RoundSignificantDigits(entry.value, 1);
}
else
{
roundedString = RoundSignificant(entry.value, 0);
roundedString = RoundSignificantDigits(entry.value, 0);
}
if (stod(roundedString) != 0.0 || m_currentCategory.supportsNegative)
{
TrimString(roundedString);
TrimTrailingZeros(roundedString);
returnVector.push_back(make_tuple(roundedString, entry.type));
}
}
@ -672,21 +674,21 @@ vector<tuple<wstring, Unit>> UnitConverter::CalculateSuggested()
wstring roundedString;
if (abs(entry.value) < 100)
{
roundedString = RoundSignificant(entry.value, 2);
roundedString = RoundSignificantDigits(entry.value, 2);
}
else if (abs(entry.value) < 1000)
{
roundedString = RoundSignificant(entry.value, 1);
roundedString = RoundSignificantDigits(entry.value, 1);
}
else
{
roundedString = RoundSignificant(entry.value, 0);
roundedString = RoundSignificantDigits(entry.value, 0);
}
// How to work out which is the best whimsical value to add to the vector?
if (stod(roundedString) != 0.0)
{
TrimString(roundedString);
TrimTrailingZeros(roundedString);
whimsicalReturnVector.push_back(make_tuple(roundedString, entry.type));
}
}
@ -789,17 +791,27 @@ void UnitConverter::InitializeSelectedUnits()
vector<Unit> curUnits = itr->second;
if (!curUnits.empty())
{
// Units may already have been initialized through UnitConverter::RestoreUserPreferences().
// Check if they have been, and if so, do not override restored units.
bool isFromUnitValid = m_fromType != EMPTY_UNIT && find(curUnits.begin(), curUnits.end(), m_fromType) != curUnits.end();
bool isToUnitValid = m_toType != EMPTY_UNIT && find(curUnits.begin(), curUnits.end(), m_toType) != curUnits.end();
if (isFromUnitValid && isToUnitValid)
{
return;
}
bool conversionSourceSet = false;
bool conversionTargetSet = false;
for (const Unit& cur : curUnits)
{
if (!conversionSourceSet && cur.isConversionSource)
if (!conversionSourceSet && cur.isConversionSource && !isFromUnitValid)
{
m_fromType = cur;
conversionSourceSet = true;
}
if (!conversionTargetSet && cur.isConversionTarget)
if (!conversionTargetSet && cur.isConversionTarget && !isToUnitValid)
{
m_toType = cur;
conversionTargetSet = true;
@ -843,100 +855,61 @@ void UnitConverter::Calculate()
{
m_returnDisplay = m_currentDisplay;
m_returnHasDecimal = m_currentHasDecimal;
TrimString(m_returnDisplay);
TrimTrailingZeros(m_returnDisplay);
UpdateViewModel();
return;
}
unordered_map<Unit, ConversionData, UnitHash> conversionTable = m_ratioMap[m_fromType];
double returnValue = stod(m_currentDisplay);
if (conversionTable[m_toType].ratio == 1.0 && conversionTable[m_toType].offset == 0.0)
if (AnyUnitIsEmpty() || (conversionTable[m_toType].ratio == 1.0 && conversionTable[m_toType].offset == 0.0))
{
m_returnDisplay = m_currentDisplay;
m_returnHasDecimal = m_currentHasDecimal;
TrimString(m_returnDisplay);
TrimTrailingZeros(m_returnDisplay);
}
else
{
returnValue = Convert(returnValue, conversionTable[m_toType]);
m_returnDisplay = RoundSignificant(returnValue, MAXIMUMDIGITSALLOWED);
TrimString(m_returnDisplay);
int numPreDecimal = (int)m_returnDisplay.size();
if (m_returnDisplay.find(L'.') != m_returnDisplay.npos)
{
numPreDecimal = (int)m_returnDisplay.find(L'.');
}
if (returnValue < 0)
{
numPreDecimal--;
}
double currentValue = stod(m_currentDisplay);
double returnValue = Convert(currentValue, conversionTable[m_toType]);
if (numPreDecimal > MAXIMUMDIGITSALLOWED || (returnValue != 0 && abs(returnValue) < MINIMUMDECIMALALLOWED))
auto isCurrencyConverter = m_currencyDataLoader != nullptr && m_currencyDataLoader->SupportsCategory(this->m_currentCategory);
if (isCurrencyConverter)
{
wstringstream out(wstringstream::out);
out << scientific << returnValue;
m_returnDisplay = out.str();
// We don't need to trim the value when it's a currency.
m_returnDisplay = RoundSignificantDigits(returnValue, MAXIMUMDIGITSALLOWED);
TrimTrailingZeros(m_returnDisplay);
}
else
{
returnValue = stod(m_returnDisplay);
wstring returnString;
if (m_currentDisplay.size() <= OPTIMALDIGITSALLOWED && abs(returnValue) >= OPTIMALDECIMALALLOWED)
int numPreDecimal = GetNumberDigitsWholeNumberPart(returnValue);
if (numPreDecimal > MAXIMUMDIGITSALLOWED || (returnValue != 0 && abs(returnValue) < MINIMUMDECIMALALLOWED))
{
returnString = RoundSignificant(returnValue, OPTIMALDIGITSALLOWED - min(numPreDecimal, OPTIMALDIGITSALLOWED));
m_returnDisplay = ToScientificNumber(returnValue);
}
else
{
returnString = RoundSignificant(returnValue, MAXIMUMDIGITSALLOWED - min(numPreDecimal, MAXIMUMDIGITSALLOWED));
int currentNumberSignificantDigits = GetNumberDigits(m_currentDisplay);
int precision = 0;
if (abs(returnValue) < OPTIMALDECIMALALLOWED)
{
precision = MAXIMUMDIGITSALLOWED;
}
else
{
// Fewer digits are needed following the decimal if the number is large,
// we calculate the number of decimals necessary based on the number of digits in the integer part.
precision = max(0, max(OPTIMALDIGITSALLOWED, min(MAXIMUMDIGITSALLOWED, currentNumberSignificantDigits)) - numPreDecimal);
}
m_returnDisplay = RoundSignificantDigits(returnValue, precision);
TrimTrailingZeros(m_returnDisplay);
}
m_returnDisplay = returnString;
TrimString(m_returnDisplay);
m_returnHasDecimal = (m_returnDisplay.find(L'.') != wstring::npos);
}
m_returnHasDecimal = (m_returnDisplay.find(L'.') != m_returnDisplay.npos);
}
UpdateViewModel();
}
/// <summary>
/// Trims out any trailing zeros or decimals in the given input string
/// </summary>
/// <param name="input">wstring to trim</param>
void UnitConverter::TrimString(wstring& returnString)
{
if (returnString.find(L'.') == m_returnDisplay.npos)
{
return;
}
wstring::iterator iter;
for (iter = returnString.end() - 1;; iter--)
{
if (*iter != L'0')
{
returnString.erase(iter + 1, returnString.end());
break;
}
}
if (*(returnString.end() - 1) == L'.')
{
returnString.erase(returnString.end() - 1, returnString.end());
}
}
/// <summary>
/// Rounds the given double to the given number of significant digits
/// </summary>
/// <param name="num">input double</param>
/// <param name="numSignificant">int number of significant digits to round to</param>
wstring UnitConverter::RoundSignificant(double num, int numSignificant)
{
wstringstream out(wstringstream::out);
out << fixed;
out.precision(numSignificant);
out << num;
return out.str();
}
void UnitConverter::UpdateCurrencySymbols()
{
if (m_currencyDataLoader != nullptr && m_vmCurrencyCallback != nullptr)

Просмотреть файл

@ -279,9 +279,7 @@ namespace UnitConversionManager
double Convert(double value, ConversionData conversionData);
std::vector<std::tuple<std::wstring, Unit>> CalculateSuggested();
void ClearValues();
void TrimString(std::wstring& input);
void InitializeSelectedUnits();
std::wstring RoundSignificant(double num, int numSignificant);
Category StringToCategory(const std::wstring& w);
std::wstring CategoryToString(const Category& c, const wchar_t* delimiter);
std::wstring UnitToString(const Unit& u, const wchar_t* delimiter);

Просмотреть файл

@ -20,3 +20,5 @@
#include <unordered_map>
#include <vector>
#include <winerror.h>
#include <iostream>
#include <math.h>

Просмотреть файл

@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#include "pch.h"
@ -31,6 +31,8 @@ using namespace Windows::UI::Xaml::Controls;
using namespace Windows::UI::Xaml::Data;
using namespace Windows::UI::Xaml::Input;
using namespace Windows::UI::Xaml::Media;
using namespace Windows::Foundation;
using namespace Concurrency;
namespace
{
@ -38,14 +40,14 @@ namespace
StringReference ClearMemoryVisibilityPropertyName(L"ClearMemoryVisibility");
}
ApplicationViewModel::ApplicationViewModel() :
m_CalculatorViewModel(nullptr),
m_DateCalcViewModel(nullptr),
m_GraphingCalcViewModel(nullptr),
m_ConverterViewModel(nullptr),
m_PreviousMode(ViewMode::None),
m_mode(ViewMode::None),
m_categories(nullptr)
ApplicationViewModel::ApplicationViewModel()
: m_CalculatorViewModel(nullptr)
, m_DateCalcViewModel(nullptr)
, m_GraphingCalcViewModel(nullptr)
, m_ConverterViewModel(nullptr)
, m_PreviousMode(ViewMode::None)
, m_mode(ViewMode::None)
, m_categories(nullptr)
{
SetMenuCategories();
}
@ -56,6 +58,7 @@ void ApplicationViewModel::Mode::set(ViewMode value)
{
PreviousMode = m_mode;
m_mode = value;
SetDisplayNormalAlwaysOnTopOption();
OnModeChanged();
RaisePropertyChanged(ModePropertyName);
}
@ -83,7 +86,7 @@ void ApplicationViewModel::Initialize(ViewMode mode)
}
catch (const std::exception& e)
{
TraceLogger::GetInstance().LogStandardException(__FUNCTIONW__, e);
TraceLogger::GetInstance().LogStandardException(mode, __FUNCTIONW__, e);
if (!TryRecoverFromNavigationModeFailure())
{
// Could not navigate to standard mode either.
@ -93,7 +96,7 @@ void ApplicationViewModel::Initialize(ViewMode mode)
}
catch (Exception ^ e)
{
TraceLogger::GetInstance().LogPlatformException(__FUNCTIONW__, e);
TraceLogger::GetInstance().LogPlatformException(mode, __FUNCTIONW__, e);
if (!TryRecoverFromNavigationModeFailure())
{
// Could not navigate to standard mode either.
@ -122,10 +125,8 @@ bool ApplicationViewModel::TryRecoverFromNavigationModeFailure()
void ApplicationViewModel::OnModeChanged()
{
assert(NavCategory::IsValidViewMode(m_mode));
TraceLogger::GetInstance().LogModeChangeBegin(m_PreviousMode, m_mode, ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
if (NavCategory::IsCalculatorViewMode(m_mode))
{
TraceLogger::GetInstance().LogCalculatorModeViewed(m_mode, ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
if (!m_CalculatorViewModel)
{
m_CalculatorViewModel = ref new StandardCalculatorViewModel();
@ -141,7 +142,6 @@ void ApplicationViewModel::OnModeChanged()
}
else if (NavCategory::IsDateCalculatorViewMode(m_mode))
{
TraceLogger::GetInstance().LogDateCalculatorModeViewed(m_mode, ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
if (!m_DateCalcViewModel)
{
m_DateCalcViewModel = ref new DateCalculatorViewModel();
@ -149,7 +149,6 @@ void ApplicationViewModel::OnModeChanged()
}
else if (NavCategory::IsConverterViewMode(m_mode))
{
TraceLogger::GetInstance().LogConverterModeViewed(m_mode, ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
if (!m_ConverterViewModel)
{
auto dataLoader = make_shared<UnitConverterDataLoader>(ref new GeographicRegion());
@ -163,13 +162,21 @@ void ApplicationViewModel::OnModeChanged()
auto resProvider = AppResourceProvider::GetInstance();
CategoryName = resProvider.GetResourceString(NavCategory::GetNameResourceKey(m_mode));
// This is the only place where a ViewMode enum should be cast to an int.
//
// Cast mode to an int in order to save it to app data.
// Save the changed mode, so that the new window launches in this mode.
// Don't save until after we have adjusted to the new mode, so we don't save a mode that fails to load.
ApplicationData::Current->LocalSettings->Values->Insert(ModePropertyName, NavCategory::Serialize(m_mode));
TraceLogger::GetInstance().LogModeChangeEnd(m_mode, ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
// Log ModeChange event when not first launch, log WindowCreated on first launch
if (NavCategory::IsValidViewMode(m_PreviousMode))
{
TraceLogger::GetInstance().LogModeChange(m_mode);
}
else
{
TraceLogger::GetInstance().LogWindowCreated(m_mode, ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
}
RaisePropertyChanged(ClearMemoryVisibilityPropertyName);
}
@ -208,3 +215,62 @@ void ApplicationViewModel::SetMenuCategories()
// property setter logic.
Categories = NavCategoryGroup::CreateMenuOptions();
}
void ApplicationViewModel::ToggleAlwaysOnTop(float width, float height)
{
HandleToggleAlwaysOnTop(width, height);
}
#pragma optimize("", off)
task<void> ApplicationViewModel::HandleToggleAlwaysOnTop(float width, float height)
{
if (ApplicationView::GetForCurrentView()->ViewMode == ApplicationViewMode::CompactOverlay)
{
ApplicationDataContainer ^ localSettings = ApplicationData::Current->LocalSettings;
localSettings->Values->Insert(WidthLocalSettings, width);
localSettings->Values->Insert(HeightLocalSettings, height);
bool success = co_await ApplicationView::GetForCurrentView()->TryEnterViewModeAsync(ApplicationViewMode::Default);
CalculatorViewModel->AreHistoryShortcutsEnabled = success;
CalculatorViewModel->HistoryVM->AreHistoryShortcutsEnabled = success;
CalculatorViewModel->IsAlwaysOnTop = !success;
IsAlwaysOnTop = !success;
}
else
{
ApplicationDataContainer ^ localSettings = ApplicationData::Current->LocalSettings;
ViewModePreferences ^ compactOptions = ViewModePreferences::CreateDefault(ApplicationViewMode::CompactOverlay);
if (!localSettings->Values->GetView()->HasKey(LaunchedLocalSettings))
{
compactOptions->CustomSize = Size(320, 394);
localSettings->Values->Insert(LaunchedLocalSettings, true);
}
else
{
if (localSettings->Values->GetView()->HasKey(WidthLocalSettings) && localSettings->Values->GetView()->HasKey(HeightLocalSettings))
{
float oldWidth = safe_cast<IPropertyValue ^>(localSettings->Values->GetView()->Lookup(WidthLocalSettings))->GetSingle();
float oldHeight = safe_cast<IPropertyValue ^>(localSettings->Values->GetView()->Lookup(HeightLocalSettings))->GetSingle();
compactOptions->CustomSize = Size(oldWidth, oldHeight);
}
else
{
compactOptions->CustomSize = Size(320, 394);
}
}
bool success = co_await ApplicationView::GetForCurrentView()->TryEnterViewModeAsync(ApplicationViewMode::CompactOverlay, compactOptions);
CalculatorViewModel->AreHistoryShortcutsEnabled = !success;
CalculatorViewModel->HistoryVM->AreHistoryShortcutsEnabled = !success;
CalculatorViewModel->IsAlwaysOnTop = success;
IsAlwaysOnTop = success;
}
SetDisplayNormalAlwaysOnTopOption();
};
#pragma optimize("", on)
void ApplicationViewModel::SetDisplayNormalAlwaysOnTopOption()
{
DisplayNormalAlwaysOnTopOption =
m_mode == ViewMode::Standard && ApplicationView::GetForCurrentView()->IsViewModeSupported(ApplicationViewMode::CompactOverlay) && !IsAlwaysOnTop;
}

Просмотреть файл

@ -20,13 +20,17 @@ namespace CalculatorApp
void Initialize(CalculatorApp::Common::ViewMode mode); // Use for first init, use deserialize for rehydration
OBSERVABLE_OBJECT();
OBSERVABLE_PROPERTY_RW(StandardCalculatorViewModel^, CalculatorViewModel);
OBSERVABLE_PROPERTY_RW(DateCalculatorViewModel^, DateCalcViewModel);
OBSERVABLE_PROPERTY_RW(GraphingCalculatorViewModel^, GraphingCalcViewModel);
OBSERVABLE_PROPERTY_RW(UnitConverterViewModel^, ConverterViewModel);
OBSERVABLE_PROPERTY_RW(StandardCalculatorViewModel ^, CalculatorViewModel);
OBSERVABLE_PROPERTY_RW(DateCalculatorViewModel ^, DateCalcViewModel);
OBSERVABLE_PROPERTY_RW(GraphingCalculatorViewModel ^, GraphingCalcViewModel);
OBSERVABLE_PROPERTY_RW(UnitConverterViewModel ^, ConverterViewModel);
OBSERVABLE_PROPERTY_RW(CalculatorApp::Common::ViewMode, PreviousMode);
OBSERVABLE_PROPERTY_R(bool, IsAlwaysOnTop);
OBSERVABLE_NAMED_PROPERTY_RW(Platform::String ^, CategoryName);
// Indicates whether calculator is currently in standard mode _and_ supports CompactOverlay _and_ is not in Always-on-Top mode
OBSERVABLE_PROPERTY_R(bool, DisplayNormalAlwaysOnTopOption);
COMMAND_FOR_METHOD(CopyCommand, ApplicationViewModel::OnCopyCommand);
COMMAND_FOR_METHOD(PasteCommand, ApplicationViewModel::OnPasteCommand);
@ -66,6 +70,32 @@ namespace CalculatorApp
}
}
static property Platform::String ^ LaunchedLocalSettings
{
Platform::String ^ get()
{
return Platform::StringReference(L"calculatorAlwaysOnTopLaunched");
}
}
static property Platform::String ^ WidthLocalSettings
{
Platform::String ^ get()
{
return Platform::StringReference(L"calculatorAlwaysOnTopLastWidth");
}
}
static property Platform::String ^ HeightLocalSettings
{
Platform::String ^ get()
{
return Platform::StringReference(L"calculatorAlwaysOnTopLastHeight");
}
}
void ToggleAlwaysOnTop(float width, float height);
private:
bool TryRecoverFromNavigationModeFailure();
@ -78,6 +108,8 @@ namespace CalculatorApp
CalculatorApp::Common::ViewMode m_mode;
Windows::Foundation::Collections::IObservableVector<CalculatorApp::Common::NavCategoryGroup ^> ^ m_categories;
Concurrency::task<void> HandleToggleAlwaysOnTop(float width, float height);
void SetDisplayNormalAlwaysOnTopOption();
};
}
}

Просмотреть файл

@ -42,8 +42,8 @@
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
<AppContainerApplication>true</AppContainerApplication>
<ApplicationType>Windows Store</ApplicationType>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion>10.0.18362.0</WindowsTargetPlatformMinVersion>
<WindowsTargetPlatformVersion>10.0.18362.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion>10.0.17134.0</WindowsTargetPlatformMinVersion>
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
@ -308,7 +308,7 @@
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(IsStoreBuild)' == 'True'">
<ClCompile>
<AdditionalOptions>/DSEND_TELEMETRY %(AdditionalOptions)</AdditionalOptions>
<AdditionalOptions>/DSEND_DIAGNOSTICS %(AdditionalOptions)</AdditionalOptions>
</ClCompile>
</ItemDefinitionGroup>
<ItemGroup>
@ -322,6 +322,7 @@
<ClInclude Include="Common\Automation\NarratorNotifier.h" />
<ClInclude Include="Common\Automation\NotificationHost.h" />
<ClInclude Include="Common\BindableBase.h" />
<ClInclude Include="Common\BitLength.h" />
<ClInclude Include="Common\CalculatorButtonPressedEventArgs.h" />
<ClInclude Include="Common\CalculatorButtonUser.h" />
<ClInclude Include="Common\CalculatorDisplay.h" />

Просмотреть файл

@ -1,95 +1,247 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Common">
<UniqueIdentifier>{1daab7c4-63f6-4266-a259-f34acad66d09}</UniqueIdentifier>
</Filter>
<Filter Include="Common\Automation">
<UniqueIdentifier>{8d4edf06-c312-4312-978a-b6c2beb8295a}</UniqueIdentifier>
</Filter>
<Filter Include="DataLoaders">
<UniqueIdentifier>{0184f727-b8aa-4af8-a699-63f1b56e7853}</UniqueIdentifier>
</Filter>
<Filter Include="GraphingCalculator">
<UniqueIdentifier>{cf7dca32-9727-4f98-83c3-1c0ca7dd1e0c}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="pch.cpp" />
<ClCompile Include="ApplicationViewModel.cpp" />
<ClCompile Include="Common\AppResourceProvider.cpp" />
<ClCompile Include="Common\Automation\LiveRegionHost.cpp" />
<ClCompile Include="Common\Automation\NarratorAnnouncement.cpp" />
<ClCompile Include="Common\Automation\NarratorAnnouncementHostFactory.cpp" />
<ClCompile Include="Common\Automation\NarratorNotifier.cpp" />
<ClCompile Include="Common\Automation\NotificationHost.cpp" />
<ClCompile Include="Common\BindableBase.cpp" />
<ClCompile Include="Common\CalculatorButtonPressedEventArgs.cpp" />
<ClCompile Include="Common\CalculatorDisplay.cpp" />
<ClCompile Include="Common\ConversionResultTaskHelper.cpp" />
<ClCompile Include="Common\CopyPasteManager.cpp" />
<ClCompile Include="Common\DateCalculator.cpp" />
<ClCompile Include="Common\EngineResourceProvider.cpp" />
<ClCompile Include="Common\ExpressionCommandDeserializer.cpp" />
<ClCompile Include="Common\ExpressionCommandSerializer.cpp" />
<ClCompile Include="Common\KeyboardShortcutManager.cpp" />
<ClCompile Include="Common\LocalizationService.cpp" />
<ClCompile Include="Common\NavCategory.cpp" />
<ClCompile Include="Common\NetworkManager.cpp" />
<ClCompile Include="Common\TraceLogger.cpp" />
<ClCompile Include="Common\Utils.cpp" />
<ClCompile Include="DataLoaders\CurrencyDataLoader.cpp" />
<ClCompile Include="DataLoaders\CurrencyHttpClient.cpp" />
<ClCompile Include="DataLoaders\UnitConverterDataLoader.cpp" />
<ClCompile Include="DateCalculatorViewModel.cpp" />
<ClCompile Include="GraphingCalculator\EquationViewModel.cpp" />
<ClCompile Include="GraphingCalculator\GraphingCalculatorViewModel.cpp" />
<ClCompile Include="HistoryItemViewModel.cpp" />
<ClCompile Include="HistoryViewModel.cpp" />
<ClCompile Include="MemoryItemViewModel.cpp" />
<ClCompile Include="pch.cpp" />
<ClCompile Include="StandardCalculatorViewModel.cpp" />
<ClCompile Include="UnitConverterViewModel.cpp" />
<ClCompile Include="ViewState.cpp" />
<ClCompile Include="Common\AppResourceProvider.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\BindableBase.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\CalculatorButtonPressedEventArgs.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\CalculatorDisplay.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\ConversionResultTaskHelper.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\CopyPasteManager.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\DateCalculator.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\EngineResourceProvider.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\ExpressionCommandDeserializer.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\ExpressionCommandSerializer.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\KeyboardShortcutManager.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\LocalizationService.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\NavCategory.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\NetworkManager.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\TraceLogger.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\Utils.cpp">
<Filter>Common</Filter>
</ClCompile>
<ClCompile Include="Common\Automation\LiveRegionHost.cpp">
<Filter>Common\Automation</Filter>
</ClCompile>
<ClCompile Include="Common\Automation\NarratorAnnouncement.cpp">
<Filter>Common\Automation</Filter>
</ClCompile>
<ClCompile Include="Common\Automation\NarratorAnnouncementHostFactory.cpp">
<Filter>Common\Automation</Filter>
</ClCompile>
<ClCompile Include="Common\Automation\NarratorNotifier.cpp">
<Filter>Common\Automation</Filter>
</ClCompile>
<ClCompile Include="Common\Automation\NotificationHost.cpp">
<Filter>Common\Automation</Filter>
</ClCompile>
<ClCompile Include="DataLoaders\CurrencyDataLoader.cpp">
<Filter>DataLoaders</Filter>
</ClCompile>
<ClCompile Include="DataLoaders\CurrencyHttpClient.cpp">
<Filter>DataLoaders</Filter>
</ClCompile>
<ClCompile Include="DataLoaders\UnitConverterDataLoader.cpp">
<Filter>DataLoaders</Filter>
</ClCompile>
<ClCompile Include="GraphingCalculator\EquationViewModel.cpp">
<Filter>GraphingCalculator</Filter>
</ClInclude>
<ClCompile Include="GraphingCalculator\GraphingCalculatorViewModel.cpp">
<Filter>GraphingCalculator</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<ClInclude Include="pch.h" />
<ClInclude Include="targetver.h" />
<ClInclude Include="ApplicationViewModel.h" />
<ClInclude Include="Common\AlwaysSelectedCollectionView.h" />
<ClInclude Include="Common\AppResourceProvider.h" />
<ClInclude Include="Common\Automation\INarratorAnnouncementHost.h" />
<ClInclude Include="Common\Automation\LiveRegionHost.h" />
<ClInclude Include="Common\Automation\NarratorAnnouncement.h" />
<ClInclude Include="Common\Automation\NarratorAnnouncementHostFactory.h" />
<ClInclude Include="Common\Automation\NarratorNotifier.h" />
<ClInclude Include="Common\Automation\NotificationHost.h" />
<ClInclude Include="Common\BindableBase.h" />
<ClInclude Include="Common\CalculatorButtonPressedEventArgs.h" />
<ClInclude Include="Common\CalculatorButtonUser.h" />
<ClInclude Include="Common\CalculatorDisplay.h" />
<ClInclude Include="Common\ConversionResultTaskHelper.h" />
<ClInclude Include="Common\CopyPasteManager.h" />
<ClInclude Include="Common\DateCalculator.h" />
<ClInclude Include="Common\DelegateCommand.h" />
<ClInclude Include="Common\DisplayExpressionToken.h" />
<ClInclude Include="Common\EngineResourceProvider.h" />
<ClInclude Include="Common\ExpressionCommandDeserializer.h" />
<ClInclude Include="Common\ExpressionCommandSerializer.h" />
<ClInclude Include="Common\KeyboardShortcutManager.h" />
<ClInclude Include="Common\LocalizationService.h" />
<ClInclude Include="Common\LocalizationSettings.h" />
<ClInclude Include="Common\LocalizationStringUtil.h" />
<ClInclude Include="Common\MyVirtualKey.h" />
<ClInclude Include="Common\NavCategory.h" />
<ClInclude Include="Common\NetworkManager.h" />
<ClInclude Include="Common\TraceActivity.h" />
<ClInclude Include="Common\TraceLogger.h" />
<ClInclude Include="Common\Utils.h" />
<ClInclude Include="Common\ValidatingConverters.h" />
<ClInclude Include="DataLoaders\CurrencyDataLoader.h" />
<ClInclude Include="DataLoaders\CurrencyHttpClient.h" />
<ClInclude Include="DataLoaders\ICurrencyHttpClient.h" />
<ClInclude Include="DataLoaders\UnitConverterDataConstants.h" />
<ClInclude Include="DataLoaders\UnitConverterDataLoader.h" />
<ClInclude Include="DateCalculatorViewModel.h" />
<ClInclude Include="GraphingCalculator\EquationViewModel.h" />
<ClInclude Include="GraphingCalculator\GraphingCalculatorViewModel.h" />
<ClInclude Include="HistoryItemViewModel.h" />
<ClInclude Include="HistoryViewModel.h" />
<ClInclude Include="MemoryItemViewModel.h" />
<ClInclude Include="pch.h" />
<ClInclude Include="StandardCalculatorViewModel.h" />
<ClInclude Include="targetver.h" />
<ClInclude Include="UnitConverterViewModel.h" />
<ClInclude Include="ViewState.h" />
<ClInclude Include="DataLoaders\DataLoaderMockConstants.h" />
<ClInclude Include="Common\AlwaysSelectedCollectionView.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\AppResourceProvider.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\BindableBase.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\CalculatorButtonPressedEventArgs.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\CalculatorButtonUser.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\CalculatorDisplay.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\ConversionResultTaskHelper.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\CopyPasteManager.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\DateCalculator.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\DelegateCommand.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\DisplayExpressionToken.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\EngineResourceProvider.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\ExpressionCommandDeserializer.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\ExpressionCommandSerializer.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\KeyboardShortcutManager.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\LocalizationService.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\LocalizationSettings.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\LocalizationStringUtil.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\MyVirtualKey.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\NavCategory.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\NetworkManager.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\TraceLogger.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\Utils.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\ValidatingConverters.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Common\Automation\INarratorAnnouncementHost.h">
<Filter>Common\Automation</Filter>
</ClInclude>
<ClInclude Include="Common\Automation\LiveRegionHost.h">
<Filter>Common\Automation</Filter>
</ClInclude>
<ClInclude Include="Common\Automation\NarratorAnnouncement.h">
<Filter>Common\Automation</Filter>
</ClInclude>
<ClInclude Include="Common\Automation\NarratorAnnouncementHostFactory.h">
<Filter>Common\Automation</Filter>
</ClInclude>
<ClInclude Include="Common\Automation\NarratorNotifier.h">
<Filter>Common\Automation</Filter>
</ClInclude>
<ClInclude Include="Common\Automation\NotificationHost.h">
<Filter>Common\Automation</Filter>
</ClInclude>
<ClInclude Include="DataLoaders\CurrencyDataLoader.h">
<Filter>DataLoaders</Filter>
</ClInclude>
<ClInclude Include="DataLoaders\CurrencyHttpClient.h">
<Filter>DataLoaders</Filter>
</ClInclude>
<ClInclude Include="DataLoaders\ICurrencyHttpClient.h">
<Filter>DataLoaders</Filter>
</ClInclude>
<ClInclude Include="DataLoaders\UnitConverterDataConstants.h">
<Filter>DataLoaders</Filter>
</ClInclude>
<ClInclude Include="DataLoaders\UnitConverterDataLoader.h">
<Filter>DataLoaders</Filter>
</ClInclude>
<ClInclude Include="Common\TraceActivity.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="DataLoaders\DataLoaderMockConstants.h">
<Filter>DataLoaders</Filter>
</ClInclude>
<ClInclude Include="DataLoaders\DataLoaderConstants.h">
<Filter>DataLoaders</Filter>
</ClInclude>
<ClInclude Include="Common\BitLength.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="GraphingCalculator\EquationViewModel.h">
<Filter>GraphingCalculator</Filter>
</ClInclude>
<ClInclude Include="GraphingCalculator\GraphingCalculatorViewModel.h">
<Filter>GraphingCalculator</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<None Include="DataLoaders\DefaultFromToCurrency.json" />
<None Include="DataLoaders\DefaultFromToCurrency.json">
<Filter>DataLoaders</Filter>
</None>
<None Include="packages.config" />
</ItemGroup>
</Project>

Просмотреть файл

@ -0,0 +1,17 @@
#pragma once
namespace CalculatorApp
{
namespace Common
{
public
enum class BitLength : int
{
BitLengthUnknown = -1,
BitLengthByte = 8,
BitLengthWord = 16,
BitLengthDWord = 32,
BitLengthQWord = 64,
};
}
}

Просмотреть файл

@ -12,171 +12,35 @@ namespace CalculatorApp
public
enum class NumbersAndOperatorsEnum
{
Zero = (int) CM::Command::Command0,
One = (int) CM::Command::Command1,
Two = (int) CM::Command::Command2,
Three = (int) CM::Command::Command3,
Four = (int) CM::Command::Command4,
Five = (int) CM::Command::Command5,
Six = (int) CM::Command::Command6,
Seven = (int) CM::Command::Command7,
Eight = (int) CM::Command::Command8,
Nine = (int) CM::Command::Command9,
Add = (int) CM::Command::CommandADD,
Subtract = (int) CM::Command::CommandSUB,
Multiply = (int) CM::Command::CommandMUL,
Divide = (int) CM::Command::CommandDIV,
Invert = (int) CM::Command::CommandREC,
Equals = (int) CM::Command::CommandEQU,
Decimal = (int) CM::Command::CommandPNT,
Sqrt = (int) CM::Command::CommandSQRT,
Percent = (int) CM::Command::CommandPERCENT,
Negate = (int) CM::Command::CommandSIGN,
Backspace = (int) CM::Command::CommandBACK,
ClearEntry = (int) CM::Command::CommandCENTR,
Clear = (int) CM::Command::CommandCLEAR,
Degree = (int) CM::Command::CommandDEG,
Radians = (int) CM::Command::CommandRAD,
Grads = (int) CM::Command::CommandGRAD,
Degrees = (int) CM::Command::CommandDegrees,
OpenParenthesis = (int) CM::Command::CommandOPENP,
CloseParenthesis = (int) CM::Command::CommandCLOSEP,
Pi = (int) CM::Command::CommandPI,
Sin = (int) CM::Command::CommandSIN,
Cos = (int) CM::Command::CommandCOS,
Tan = (int) CM::Command::CommandTAN,
Factorial = (int) CM::Command::CommandFAC,
XPower2 = (int) CM::Command::CommandSQR,
Mod = (int) CM::Command::CommandMOD,
FToE = (int) CM::Command::CommandFE,
LogBaseE = (int) CM::Command::CommandLN,
InvSin = (int) CM::Command::CommandASIN,
InvCos = (int) CM::Command::CommandACOS,
InvTan = (int) CM::Command::CommandATAN,
LogBase10 = (int) CM::Command::CommandLOG,
XPowerY = (int) CM::Command::CommandPWR,
YRootX = (int) CM::Command::CommandROOT,
TenPowerX = (int) CM::Command::CommandPOW10,
EPowerX = (int) CM::Command::CommandPOWE,
Exp = (int) CM::Command::CommandEXP,
IsScientificMode = (int) CM::Command::ModeScientific,
IsStandardMode = (int) CM::Command::ModeBasic,
None = (int) CM::Command::CommandNULL,
IsProgrammerMode = (int) CM::Command::ModeProgrammer,
And = (int) CM::Command::CommandAnd,
Ror = (int) CM::Command::CommandROR,
Rol = (int) CM::Command::CommandROL,
Or = (int) CM::Command::CommandOR,
Lsh = (int) CM::Command::CommandLSHF,
Rsh = (int) CM::Command::CommandRSHF,
Xor = (int) CM::Command::CommandXor,
Not = (int) CM::Command::CommandNot,
A = (int) CM::Command::CommandA,
B = (int) CM::Command::CommandB,
C = (int) CM::Command::CommandC,
D = (int) CM::Command::CommandD,
E = (int) CM::Command::CommandE,
F = (int) CM::Command::CommandF,
Memory, // This is the memory button. Doesn't have a direct mapping to the CalcEngine.
Sinh = (int) CM::Command::CommandSINH,
Cosh = (int) CM::Command::CommandCOSH,
Tanh = (int) CM::Command::CommandTANH,
InvSinh = (int) CM::Command::CommandASINH,
InvCosh = (int) CM::Command::CommandACOSH,
InvTanh = (int) CM::Command::CommandATANH,
Cube = (int) CM::Command::CommandCUB,
DMS = (int) CM::Command::CommandDMS,
Hyp = (int)CM::Command::CommandHYP,
HexButton = (int)CM::Command::CommandHex,
DecButton = (int)CM::Command::CommandDec,
OctButton = (int)CM::Command::CommandOct,
BinButton = (int)CM::Command::CommandBin,
Qword = (int)CM::Command::CommandQword,
Dword = (int)CM::Command::CommandDword,
Word = (int)CM::Command::CommandWord,
Byte = (int)CM::Command::CommandByte,
Plot,
X,
Y,
BINSTART = (int) CM::Command::CommandBINEDITSTART,
BINPOS0 = (int) CM::Command::CommandBINPOS0,
BINPOS1 = (int) CM::Command::CommandBINPOS1,
BINPOS2 = (int) CM::Command::CommandBINPOS2,
BINPOS3 = (int) CM::Command::CommandBINPOS3,
BINPOS4 = (int) CM::Command::CommandBINPOS4,
BINPOS5 = (int) CM::Command::CommandBINPOS5,
BINPOS6 = (int) CM::Command::CommandBINPOS6,
BINPOS7 = (int) CM::Command::CommandBINPOS7,
BINPOS8 = (int) CM::Command::CommandBINPOS8,
BINPOS9 = (int) CM::Command::CommandBINPOS9,
BINPOS10 = (int) CM::Command::CommandBINPOS10,
BINPOS11 = (int) CM::Command::CommandBINPOS11,
BINPOS12 = (int) CM::Command::CommandBINPOS12,
BINPOS13 = (int) CM::Command::CommandBINPOS13,
BINPOS14 = (int) CM::Command::CommandBINPOS14,
BINPOS15 = (int) CM::Command::CommandBINPOS15,
BINPOS16 = (int) CM::Command::CommandBINPOS16,
BINPOS17 = (int) CM::Command::CommandBINPOS17,
BINPOS18 = (int) CM::Command::CommandBINPOS18,
BINPOS19 = (int) CM::Command::CommandBINPOS19,
BINPOS20 = (int) CM::Command::CommandBINPOS20,
BINPOS21 = (int) CM::Command::CommandBINPOS21,
BINPOS22 = (int) CM::Command::CommandBINPOS22,
BINPOS23 = (int) CM::Command::CommandBINPOS23,
BINPOS24 = (int) CM::Command::CommandBINPOS24,
BINPOS25 = (int) CM::Command::CommandBINPOS25,
BINPOS26 = (int) CM::Command::CommandBINPOS26,
BINPOS27 = (int) CM::Command::CommandBINPOS27,
BINPOS28 = (int) CM::Command::CommandBINPOS28,
BINPOS29 = (int) CM::Command::CommandBINPOS29,
BINPOS30 = (int) CM::Command::CommandBINPOS30,
BINPOS31 = (int) CM::Command::CommandBINPOS31,
BINPOS32 = (int) CM::Command::CommandBINPOS32,
BINPOS33 = (int) CM::Command::CommandBINPOS33,
BINPOS34 = (int) CM::Command::CommandBINPOS34,
BINPOS35 = (int) CM::Command::CommandBINPOS35,
BINPOS36 = (int) CM::Command::CommandBINPOS36,
BINPOS37 = (int) CM::Command::CommandBINPOS37,
BINPOS38 = (int) CM::Command::CommandBINPOS38,
BINPOS39 = (int) CM::Command::CommandBINPOS39,
BINPOS40 = (int) CM::Command::CommandBINPOS40,
BINPOS41 = (int) CM::Command::CommandBINPOS41,
BINPOS42 = (int) CM::Command::CommandBINPOS42,
BINPOS43 = (int) CM::Command::CommandBINPOS43,
BINPOS44 = (int) CM::Command::CommandBINPOS44,
BINPOS45 = (int) CM::Command::CommandBINPOS45,
BINPOS46 = (int) CM::Command::CommandBINPOS46,
BINPOS47 = (int) CM::Command::CommandBINPOS47,
BINPOS48 = (int) CM::Command::CommandBINPOS48,
BINPOS49 = (int) CM::Command::CommandBINPOS49,
BINPOS50 = (int) CM::Command::CommandBINPOS50,
BINPOS51 = (int) CM::Command::CommandBINPOS51,
BINPOS52 = (int) CM::Command::CommandBINPOS52,
BINPOS53 = (int) CM::Command::CommandBINPOS53,
BINPOS54 = (int) CM::Command::CommandBINPOS54,
BINPOS55 = (int) CM::Command::CommandBINPOS55,
BINPOS56 = (int) CM::Command::CommandBINPOS56,
BINPOS57 = (int) CM::Command::CommandBINPOS57,
BINPOS58 = (int) CM::Command::CommandBINPOS58,
BINPOS59 = (int) CM::Command::CommandBINPOS59,
BINPOS60 = (int) CM::Command::CommandBINPOS60,
BINPOS61 = (int) CM::Command::CommandBINPOS61,
BINPOS62 = (int) CM::Command::CommandBINPOS62,
BINPOS63 = (int) CM::Command::CommandBINPOS63,
BINEND = (int) CM::Command::CommandBINEDITEND
};
// This contains list of functions whose usage we are tracelogging
public
enum class FunctionLogEnum
{
Zero = (int)CM::Command::Command0,
One = (int)CM::Command::Command1,
Two = (int)CM::Command::Command2,
Three = (int)CM::Command::Command3,
Four = (int)CM::Command::Command4,
Five = (int)CM::Command::Command5,
Six = (int)CM::Command::Command6,
Seven = (int)CM::Command::Command7,
Eight = (int)CM::Command::Command8,
Nine = (int)CM::Command::Command9,
Add = (int)CM::Command::CommandADD,
Subtract = (int)CM::Command::CommandSUB,
Multiply = (int)CM::Command::CommandMUL,
Divide = (int)CM::Command::CommandDIV,
Invert = (int)CM::Command::CommandREC,
Equals = (int)CM::Command::CommandEQU,
Decimal = (int)CM::Command::CommandPNT,
Sqrt = (int)CM::Command::CommandSQRT,
Percent = (int)CM::Command::CommandPERCENT,
Negate = (int)CM::Command::CommandSIGN,
Backspace = (int)CM::Command::CommandBACK,
ClearEntry = (int)CM::Command::CommandCENTR,
Clear = (int)CM::Command::CommandCLEAR,
Degree = (int)CM::Command::CommandDEG,
Radians = (int)CM::Command::CommandRAD,
Grads = (int)CM::Command::CommandGRAD,
Degrees = (int)CM::Command::CommandDegrees,
OpenParenthesis = (int)CM::Command::CommandOPENP,
CloseParenthesis = (int)CM::Command::CommandCLOSEP,
Pi = (int)CM::Command::CommandPI,
Sin = (int)CM::Command::CommandSIN,
Cos = (int)CM::Command::CommandCOS,
@ -195,10 +59,10 @@ public
TenPowerX = (int)CM::Command::CommandPOW10,
EPowerX = (int)CM::Command::CommandPOWE,
Exp = (int)CM::Command::CommandEXP,
DecButton = (int)CM::Command::CommandDec,
OctButton = (int)CM::Command::CommandOct,
HexButton = (int)CM::Command::CommandHex,
BinButton = (int)CM::Command::CommandBin,
IsScientificMode = (int)CM::Command::ModeScientific,
IsStandardMode = (int)CM::Command::ModeBasic,
None = (int)CM::Command::CommandNULL,
IsProgrammerMode = (int)CM::Command::ModeProgrammer,
And = (int)CM::Command::CommandAnd,
Ror = (int)CM::Command::CommandROR,
Rol = (int)CM::Command::CommandROL,
@ -207,13 +71,108 @@ public
Rsh = (int)CM::Command::CommandRSHF,
Xor = (int)CM::Command::CommandXor,
Not = (int)CM::Command::CommandNot,
A = (int)CM::Command::CommandA,
B = (int)CM::Command::CommandB,
C = (int)CM::Command::CommandC,
D = (int)CM::Command::CommandD,
E = (int)CM::Command::CommandE,
F = (int)CM::Command::CommandF,
Memory, // This is the memory button. Doesn't have a direct mapping to the CalcEngine.
Sinh = (int)CM::Command::CommandSINH,
Cosh = (int)CM::Command::CommandCOSH,
Tanh = (int)CM::Command::CommandTANH,
InvSinh = (int)CM::Command::CommandASINH,
InvCosh = (int)CM::Command::CommandACOSH,
InvTanh = (int)CM::Command::CommandATANH,
Cube = (int)CM::Command::CommandCUB,
DMS = (int)CM::Command::CommandDMS,
Cube = (int) CM::Command::CommandCUB,
DMS = (int) CM::Command::CommandDMS,
Hyp = (int)CM::Command::CommandHYP,
HexButton = (int)CM::Command::CommandHex,
DecButton = (int)CM::Command::CommandDec,
OctButton = (int)CM::Command::CommandOct,
BinButton = (int)CM::Command::CommandBin,
Qword = (int)CM::Command::CommandQword,
Dword = (int)CM::Command::CommandDword,
Word = (int)CM::Command::CommandWord,
Byte = (int)CM::Command::CommandByte,
Plot,
X,
Y,
BINSTART = (int)CM::Command::CommandBINEDITSTART,
BINPOS0 = (int)CM::Command::CommandBINPOS0,
BINPOS1 = (int)CM::Command::CommandBINPOS1,
BINPOS2 = (int)CM::Command::CommandBINPOS2,
BINPOS3 = (int)CM::Command::CommandBINPOS3,
BINPOS4 = (int)CM::Command::CommandBINPOS4,
BINPOS5 = (int)CM::Command::CommandBINPOS5,
BINPOS6 = (int)CM::Command::CommandBINPOS6,
BINPOS7 = (int)CM::Command::CommandBINPOS7,
BINPOS8 = (int)CM::Command::CommandBINPOS8,
BINPOS9 = (int)CM::Command::CommandBINPOS9,
BINPOS10 = (int)CM::Command::CommandBINPOS10,
BINPOS11 = (int)CM::Command::CommandBINPOS11,
BINPOS12 = (int)CM::Command::CommandBINPOS12,
BINPOS13 = (int)CM::Command::CommandBINPOS13,
BINPOS14 = (int)CM::Command::CommandBINPOS14,
BINPOS15 = (int)CM::Command::CommandBINPOS15,
BINPOS16 = (int)CM::Command::CommandBINPOS16,
BINPOS17 = (int)CM::Command::CommandBINPOS17,
BINPOS18 = (int)CM::Command::CommandBINPOS18,
BINPOS19 = (int)CM::Command::CommandBINPOS19,
BINPOS20 = (int)CM::Command::CommandBINPOS20,
BINPOS21 = (int)CM::Command::CommandBINPOS21,
BINPOS22 = (int)CM::Command::CommandBINPOS22,
BINPOS23 = (int)CM::Command::CommandBINPOS23,
BINPOS24 = (int)CM::Command::CommandBINPOS24,
BINPOS25 = (int)CM::Command::CommandBINPOS25,
BINPOS26 = (int)CM::Command::CommandBINPOS26,
BINPOS27 = (int)CM::Command::CommandBINPOS27,
BINPOS28 = (int)CM::Command::CommandBINPOS28,
BINPOS29 = (int)CM::Command::CommandBINPOS29,
BINPOS30 = (int)CM::Command::CommandBINPOS30,
BINPOS31 = (int)CM::Command::CommandBINPOS31,
BINPOS32 = (int)CM::Command::CommandBINPOS32,
BINPOS33 = (int)CM::Command::CommandBINPOS33,
BINPOS34 = (int)CM::Command::CommandBINPOS34,
BINPOS35 = (int)CM::Command::CommandBINPOS35,
BINPOS36 = (int)CM::Command::CommandBINPOS36,
BINPOS37 = (int)CM::Command::CommandBINPOS37,
BINPOS38 = (int)CM::Command::CommandBINPOS38,
BINPOS39 = (int)CM::Command::CommandBINPOS39,
BINPOS40 = (int)CM::Command::CommandBINPOS40,
BINPOS41 = (int)CM::Command::CommandBINPOS41,
BINPOS42 = (int)CM::Command::CommandBINPOS42,
BINPOS43 = (int)CM::Command::CommandBINPOS43,
BINPOS44 = (int)CM::Command::CommandBINPOS44,
BINPOS45 = (int)CM::Command::CommandBINPOS45,
BINPOS46 = (int)CM::Command::CommandBINPOS46,
BINPOS47 = (int)CM::Command::CommandBINPOS47,
BINPOS48 = (int)CM::Command::CommandBINPOS48,
BINPOS49 = (int)CM::Command::CommandBINPOS49,
BINPOS50 = (int)CM::Command::CommandBINPOS50,
BINPOS51 = (int)CM::Command::CommandBINPOS51,
BINPOS52 = (int)CM::Command::CommandBINPOS52,
BINPOS53 = (int)CM::Command::CommandBINPOS53,
BINPOS54 = (int)CM::Command::CommandBINPOS54,
BINPOS55 = (int)CM::Command::CommandBINPOS55,
BINPOS56 = (int)CM::Command::CommandBINPOS56,
BINPOS57 = (int)CM::Command::CommandBINPOS57,
BINPOS58 = (int)CM::Command::CommandBINPOS58,
BINPOS59 = (int)CM::Command::CommandBINPOS59,
BINPOS60 = (int)CM::Command::CommandBINPOS60,
BINPOS61 = (int)CM::Command::CommandBINPOS61,
BINPOS62 = (int)CM::Command::CommandBINPOS62,
BINPOS63 = (int)CM::Command::CommandBINPOS63,
BINEND = (int)CM::Command::CommandBINEDITEND,
// Enum values below are used for Tracelogging and do not map to the Calculator engine
MemoryAdd = (int)CM::Command::CommandMPLUS,
MemorySubtract = (int)CM::Command::CommandMMINUS,
MemoryRecall = (int)CM::Command::CommandRECALL,
MemoryClear = (int)CM::Command::CommandMCLEAR,
BitflipButton = 1000,
FullKeypadButton = 1001
};
}

Просмотреть файл

@ -65,7 +65,7 @@ void CopyPasteManager::CopyToClipboard(String ^ stringToCopy)
Clipboard::SetContent(dataPackage);
}
task<String ^> CopyPasteManager::GetStringToPaste(ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, int bitLengthType)
task<String ^> CopyPasteManager::GetStringToPaste(ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, BitLength bitLengthType)
{
// Retrieve the text in the clipboard
auto dataPackageView = Clipboard::GetContent();
@ -97,19 +97,19 @@ int CopyPasteManager::ClipboardTextFormat()
return -1;
}
String ^ CopyPasteManager::ValidatePasteExpression(String ^ pastedText, ViewMode mode, int programmerNumberBase, int bitLengthType)
String ^ CopyPasteManager::ValidatePasteExpression(String ^ pastedText, ViewMode mode, int programmerNumberBase, BitLength bitLengthType)
{
return CopyPasteManager::ValidatePasteExpression(pastedText, mode, NavCategory::GetGroupType(mode), programmerNumberBase, bitLengthType);
}
// return "NoOp" if pastedText is invalid else return pastedText
String ^ CopyPasteManager::ValidatePasteExpression(String ^ pastedText, ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, int bitLengthType)
String ^ CopyPasteManager::ValidatePasteExpression(String ^ pastedText, ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, BitLength bitLengthType)
{
if (pastedText->Length() > MaxPasteableLength)
{
// return NoOp to indicate don't paste anything.
TraceLogger::GetInstance().LogInvalidPastedInputOccurred(L"PastedExpressionSizeGreaterThanMaxAllowed", mode, programmerNumberBase, bitLengthType);
TraceLogger::GetInstance().LogError(mode, L"CopyPasteManager::ValidatePasteExpression", L"PastedExpressionSizeGreaterThanMaxAllowed");
return StringReference(PasteErrorString);
}
@ -129,7 +129,7 @@ String ^ CopyPasteManager::ValidatePasteExpression(String ^ pastedText, ViewMode
// Extract operands from the expression to make regex comparison easy and quick. For whole expression it was taking too much of time.
// Operands vector will have the list of operands in the pasteExpression
vector<wstring> operands = ExtractOperands(pasteExpression, mode, programmerNumberBase, bitLengthType);
vector<wstring> operands = ExtractOperands(pasteExpression, mode);
if (operands.empty())
{
// return NoOp to indicate don't paste anything.
@ -144,14 +144,14 @@ String ^ CopyPasteManager::ValidatePasteExpression(String ^ pastedText, ViewMode
// validate each operand with patterns for different modes
if (!ExpressionRegExMatch(operands, mode, modeType, programmerNumberBase, bitLengthType))
{
TraceLogger::GetInstance().LogInvalidPastedInputOccurred(L"InvalidExpressionForPresentMode", mode, programmerNumberBase, bitLengthType);
TraceLogger::GetInstance().LogError(mode, L"CopyPasteManager::ValidatePasteExpression", L"InvalidExpressionForPresentMode");
return StringReference(PasteErrorString);
}
return ref new String(pastedText->Data());
}
vector<wstring> CopyPasteManager::ExtractOperands(const wstring& pasteExpression, ViewMode mode, int programmerNumberBase, int bitLengthType)
vector<wstring> CopyPasteManager::ExtractOperands(const wstring& pasteExpression, ViewMode mode)
{
vector<wstring> operands{};
size_t lastIndex = 0;
@ -173,7 +173,7 @@ vector<wstring> CopyPasteManager::ExtractOperands(const wstring& pasteExpression
if (operands.size() >= MaxOperandCount)
{
TraceLogger::GetInstance().LogInvalidPastedInputOccurred(L"OperandCountGreaterThanMaxCount", mode, programmerNumberBase, bitLengthType);
TraceLogger::GetInstance().LogError(mode, L"CopyPasteManager::ExtractOperands", L"OperandCountGreaterThanMaxCount");
operands.clear();
return operands;
}
@ -187,7 +187,7 @@ vector<wstring> CopyPasteManager::ExtractOperands(const wstring& pasteExpression
// to disallow pasting of 1e+12345 as 1e+1234, max exponent that can be pasted is 9999.
if (expLength > MaxExponentLength)
{
TraceLogger::GetInstance().LogInvalidPastedInputOccurred(L"ExponentLengthGreaterThanMaxLength", mode, programmerNumberBase, bitLengthType);
TraceLogger::GetInstance().LogError(mode, L"CopyPasteManager::ExtractOperands", L"ExponentLengthGreaterThanMaxLength");
operands.clear();
return operands;
}
@ -241,7 +241,7 @@ vector<wstring> CopyPasteManager::ExtractOperands(const wstring& pasteExpression
return operands;
}
bool CopyPasteManager::ExpressionRegExMatch(vector<wstring> operands, ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, int bitLengthType)
bool CopyPasteManager::ExpressionRegExMatch(vector<wstring> operands, ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, BitLength bitLengthType)
{
if (operands.empty())
{
@ -317,7 +317,7 @@ bool CopyPasteManager::ExpressionRegExMatch(vector<wstring> operands, ViewMode m
return expMatched;
}
pair<size_t, uint64_t> CopyPasteManager::GetMaxOperandLengthAndValue(ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, int bitLengthType)
pair<size_t, uint64_t> CopyPasteManager::GetMaxOperandLengthAndValue(ViewMode mode, CategoryGroupType modeType, int programmerNumberBase, BitLength bitLengthType)
{
constexpr size_t defaultMaxOperandLength = 0;
constexpr uint64_t defaultMaxValue = 0;
@ -335,16 +335,16 @@ pair<size_t, uint64_t> CopyPasteManager::GetMaxOperandLengthAndValue(ViewMode mo
unsigned int bitLength = 0;
switch (bitLengthType)
{
case QwordType:
case BitLength::BitLengthQWord:
bitLength = 64;
break;
case DwordType:
case BitLength::BitLengthDWord:
bitLength = 32;
break;
case WordType:
case BitLength::BitLengthWord:
bitLength = 16;
break;
case ByteType:
case BitLength::BitLengthByte:
bitLength = 8;
break;
}

Просмотреть файл

@ -5,6 +5,7 @@
#include "AppResourceProvider.h"
#include "NavCategory.h"
#include "BitLength.h"
namespace CalculatorUnitTests
{
@ -13,10 +14,6 @@ namespace CalculatorUnitTests
namespace CalculatorApp
{
inline constexpr auto QwordType = 1;
inline constexpr auto DwordType = 2;
inline constexpr auto WordType = 3;
inline constexpr auto ByteType = 4;
inline constexpr auto HexBase = 5;
inline constexpr auto DecBase = 6;
inline constexpr auto OctBase = 7;
@ -30,7 +27,7 @@ namespace CalculatorApp
CalculatorApp::Common::ViewMode mode,
CalculatorApp::Common::CategoryGroupType modeType,
int programmerNumberBase = -1,
int bitLengthType = -1);
CalculatorApp::Common::BitLength bitLengthType = CalculatorApp::Common::BitLength::BitLengthUnknown);
static bool HasStringToPaste()
{
return ClipboardTextFormat() >= 0;
@ -41,29 +38,33 @@ namespace CalculatorApp
private:
static int ClipboardTextFormat();
static Platform::String
^ ValidatePasteExpression(Platform::String ^ pastedText, CalculatorApp::Common::ViewMode mode, int programmerNumberBase, int bitLengthType);
^ ValidatePasteExpression(
Platform::String ^ pastedText,
CalculatorApp::Common::ViewMode mode,
int programmerNumberBase,
CalculatorApp::Common::BitLength bitLengthType);
static Platform::String
^ ValidatePasteExpression(
Platform::String ^ pastedText,
CalculatorApp::Common::ViewMode mode,
CalculatorApp::Common::CategoryGroupType modeType,
int programmerNumberBase,
int bitLengthType);
CalculatorApp::Common::BitLength bitLengthType);
static std::vector<std::wstring>
ExtractOperands(const std::wstring& pasteExpression, CalculatorApp::Common::ViewMode mode, int programmerNumberBase = -1, int bitLengthType = -1);
ExtractOperands(const std::wstring& pasteExpression, CalculatorApp::Common::ViewMode mode);
static bool ExpressionRegExMatch(
std::vector<std::wstring> operands,
CalculatorApp::Common::ViewMode mode,
CalculatorApp::Common::CategoryGroupType modeType,
int programmerNumberBase = -1,
int bitLengthType = -1);
CalculatorApp::Common::BitLength bitLengthType = CalculatorApp::Common::BitLength::BitLengthUnknown);
static std::pair<size_t, uint64_t> GetMaxOperandLengthAndValue(
CalculatorApp::Common::ViewMode mode,
CalculatorApp::Common::CategoryGroupType modeType,
int programmerNumberBase = -1,
int bitLengthType = -1);
CalculatorApp::Common::BitLength bitLengthType = CalculatorApp::Common::BitLength::BitLengthUnknown);
static std::wstring SanitizeOperand(const std::wstring& operand);
static bool TryOperandToULL(const std::wstring& operand, int numberBase, unsigned long long int& result);
static size_t OperandLength(

Просмотреть файл

@ -670,10 +670,11 @@ void KeyboardShortcutManager::OnAcceleratorKeyActivated(CoreDispatcher ^, Accele
if (nullptr != vm)
{
ViewMode toMode = NavCategory::GetViewModeForVirtualKey(static_cast<MyVirtualKey>(key));
if (NavCategory::IsValidViewMode(toMode))
auto nvi = dynamic_cast<MUXC::NavigationViewItem ^>(menuItems->GetAt(NavCategory::GetFlatIndex(toMode)));
if (nvi && nvi->IsEnabled && NavCategory::IsValidViewMode(toMode))
{
vm->Mode = toMode;
navView->SelectedItem = menuItems->GetAt(NavCategory::GetFlatIndex(toMode));
navView->SelectedItem = nvi;
}
}
}

Просмотреть файл

@ -75,9 +75,24 @@ LocalizationService::LocalizationService(_In_ const wchar_t * const overridedLan
{
m_isLanguageOverrided = overridedLanguage != nullptr;
m_language = m_isLanguageOverrided ? ref new Platform::String(overridedLanguage) : ApplicationLanguages::Languages->GetAt(0);
m_flowDirection = ResourceContext::GetForCurrentView()->QualifierValues->Lookup(L"LayoutDirection")
m_flowDirection = ResourceContext::GetForViewIndependentUse()->QualifierValues->Lookup(L"LayoutDirection")
!= L"LTR" ? FlowDirection::RightToLeft : FlowDirection::LeftToRight;
wstring localeName = wstring(m_language->Data());
localeName += L".UTF8";
try
{
// Convert wstring to string for locale
int size_needed = WideCharToMultiByte(CP_UTF8, 0, &localeName[0], (int)localeName.size(), NULL, 0, NULL, NULL);
string localeNameStr(size_needed, 0);
WideCharToMultiByte(CP_UTF8, 0, &localeName[0], (int)localeName.size(), &localeNameStr[0], size_needed, NULL, NULL);
m_locale = locale(localeNameStr.data());
}
catch (...)
{
m_locale = locale("");
}
auto resourceLoader = AppResourceProvider::GetInstance();
m_fontFamilyOverride = resourceLoader.GetResourceString(L"LocalizedFontFamilyOverride");
@ -371,7 +386,7 @@ DecimalFormatter ^ LocalizationService::GetRegionalSettingsAwareDecimalFormatter
// as configured by running intl.cpl.
//
// This helper function creates a DateTimeFormatter with a TwentyFour hour clock
DateTimeFormatter ^ LocalizationService::GetRegionalSettingsAwareDateTimeFormatter(_In_ String^ format) const
DateTimeFormatter ^ LocalizationService::GetRegionalSettingsAwareDateTimeFormatter(_In_ String ^ format) const
{
IIterable<String ^> ^ languageIdentifiers = LocalizationService::GetLanguageIdentifiers();
if (languageIdentifiers == nullptr)
@ -384,7 +399,7 @@ DateTimeFormatter ^ LocalizationService::GetRegionalSettingsAwareDateTimeFormatt
// If successful, returns a formatter that respects the user's regional format settings,
// as configured by running intl.cpl.
DateTimeFormatter^ LocalizationService::GetRegionalSettingsAwareDateTimeFormatter(_In_ String ^ format, _In_ String ^ calendarIdentifier, _In_ String ^ clockIdentifier) const
DateTimeFormatter ^ LocalizationService::GetRegionalSettingsAwareDateTimeFormatter(_In_ String ^ format, _In_ String ^ calendarIdentifier, _In_ String ^ clockIdentifier) const
{
IIterable<String ^> ^ languageIdentifiers = LocalizationService::GetLanguageIdentifiers();
if (languageIdentifiers == nullptr)
@ -421,7 +436,7 @@ IIterable<String ^> ^ LocalizationService::GetLanguageIdentifiers() const
if (m_isLanguageOverrided)
{
auto overridedLanguageList = ref new Vector<String^>();
auto overridedLanguageList = ref new Vector<String ^>();
overridedLanguageList->Append(m_language);
return overridedLanguageList;
}
@ -562,3 +577,11 @@ String ^ LocalizationService::GetNarratorReadableString(String ^ rawString)
return ref new String(readableString.str().c_str());
}
void LocalizationService::Sort(std::vector<Platform::String ^>& source)
{
const collate<wchar_t>& coll = use_facet<collate<wchar_t>>(m_locale);
sort(source.begin(), source.end(), [&coll](Platform::String ^ str1, Platform::String ^ str2) {
return coll.compare(str1->Begin(), str1->End(), str2->Begin(), str2->End()) < 0;
});
}

Просмотреть файл

@ -30,9 +30,9 @@ namespace CalculatorApp
DEPENDENCY_PROPERTY_ATTACHED_WITH_DEFAULT_AND_CALLBACK(LanguageFontType, FontType, LanguageFontType::UIText);
DEPENDENCY_PROPERTY_ATTACHED_WITH_CALLBACK(double, FontSize);
internal:
static LocalizationService^ GetInstance();
static void OverrideWithLanguage(_In_ const wchar_t * const language);
internal:
static LocalizationService ^ GetInstance();
static void OverrideWithLanguage(_In_ const wchar_t* const language);
Windows::UI::Xaml::FlowDirection GetFlowDirection();
bool IsRtlLayout();
@ -43,6 +43,19 @@ namespace CalculatorApp
Windows::UI::Text::FontWeight GetFontWeightOverride();
double GetFontScaleFactorOverride(LanguageFontType fontType);
void Sort(std::vector<Platform::String ^>& source);
template <typename T>
void Sort(std::vector<T>& source, std::function<Platform::String ^ (T)> func)
{
const collate<wchar_t>& coll = use_facet<collate<wchar_t>>(m_locale);
sort(source.begin(), source.end(), [&coll, &func](T obj1, T obj2) {
Platform::String ^ str1 = func(obj1);
Platform::String ^ str2 = func(obj2);
return coll.compare(str1->Begin(), str1->End(), str2->Begin(), str2->End()) < 0;
});
}
Windows::Globalization::NumberFormatting::DecimalFormatter ^ GetRegionalSettingsAwareDecimalFormatter() const;
Windows::Globalization::DateTimeFormatting::DateTimeFormatter ^ GetRegionalSettingsAwareDateTimeFormatter(_In_ Platform::String ^ format) const;
Windows::Globalization::DateTimeFormatting::DateTimeFormatter ^ GetRegionalSettingsAwareDateTimeFormatter(
@ -76,15 +89,16 @@ namespace CalculatorApp
static LocalizationService ^ s_singletonInstance;
Windows::Globalization::Fonts::LanguageFontGroup ^ m_fontGroup;
Platform::String ^ m_language;
Windows::UI::Xaml::FlowDirection m_flowDirection;
bool m_overrideFontApiValues;
Platform::String ^ m_fontFamilyOverride;
bool m_isLanguageOverrided;
Windows::UI::Text::FontWeight m_fontWeightOverride;
double m_uiTextFontScaleFactorOverride;
double m_uiCaptionFontScaleFactorOverride;
Windows::Globalization::Fonts::LanguageFontGroup ^ m_fontGroup;
Platform::String ^ m_language;
Windows::UI::Xaml::FlowDirection m_flowDirection;
bool m_overrideFontApiValues;
Platform::String ^ m_fontFamilyOverride;
bool m_isLanguageOverrided;
Windows::UI::Text::FontWeight m_fontWeightOverride;
double m_uiTextFontScaleFactorOverride;
double m_uiCaptionFontScaleFactorOverride;
std::locale m_locale;
};
}

Просмотреть файл

@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#include "pch.h"
@ -37,39 +37,163 @@ static constexpr int VOLUME_ID = 4;
static constexpr int LENGTH_ID = 5;
static constexpr int WEIGHT_ID = 6;
static constexpr int TEMPERATURE_ID = 7;
static constexpr int ENERGY_ID = 8;
static constexpr int AREA_ID = 9;
static constexpr int SPEED_ID = 10;
static constexpr int TIME_ID = 11;
static constexpr int POWER_ID = 12;
static constexpr int DATA_ID = 13;
static constexpr int PRESSURE_ID = 14;
static constexpr int ANGLE_ID = 15;
static constexpr int CURRENCY_ID = 16;
static constexpr int ENERGY_ID = 8;
static constexpr int AREA_ID = 9;
static constexpr int SPEED_ID = 10;
static constexpr int TIME_ID = 11;
static constexpr int POWER_ID = 12;
static constexpr int DATA_ID = 13;
static constexpr int PRESSURE_ID = 14;
static constexpr int ANGLE_ID = 15;
static constexpr int CURRENCY_ID = 16;
static constexpr int GRAPHING_ID = 17;
// ^^^ THESE CONSTANTS SHOULD NEVER CHANGE ^^^
// The order of items in this list determines the order of items in the menu.
static constexpr array<const NavCategoryInitializer, 18> s_categoryManifest = {
NavCategoryInitializer { ViewMode::Standard, STANDARD_ID, L"Standard", L"StandardMode", L"\uE8EF", CategoryGroupType::Calculator, MyVirtualKey::Number1, SUPPORTS_ALL },
NavCategoryInitializer { ViewMode::Scientific, SCIENTIFIC_ID, L"Scientific", L"ScientificMode", L"\uF196", CategoryGroupType::Calculator, MyVirtualKey::Number2, SUPPORTS_ALL },
NavCategoryInitializer { ViewMode::Programmer, PROGRAMMER_ID, L"Programmer", L"ProgrammerMode", L"\uECCE", CategoryGroupType::Calculator, MyVirtualKey::Number3, SUPPORTS_ALL },
NavCategoryInitializer { ViewMode::Date, DATE_ID, L"Date", L"DateCalculationMode", L"\uE787", CategoryGroupType::Calculator, MyVirtualKey::Number4, SUPPORTS_ALL },
NavCategoryInitializer { ViewMode::Graphing, GRAPHING_ID, L"Graphing", L"GraphingCalculatorMode", L"\uF770", CategoryGroupType::Calculator, MyVirtualKey::Number5, SUPPORTS_ALL },
NavCategoryInitializer { ViewMode::Currency, CURRENCY_ID, L"Currency", L"CategoryName_Currency", L"\uEB0D", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Volume, VOLUME_ID, L"Volume", L"CategoryName_Volume", L"\uF1AA", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Length, LENGTH_ID, L"Length", L"CategoryName_Length", L"\uECC6", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Weight, WEIGHT_ID, L"Weight and Mass", L"CategoryName_Weight", L"\uF4C1", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Temperature, TEMPERATURE_ID, L"Temperature", L"CategoryName_Temperature", L"\uE7A3", CategoryGroupType::Converter, MyVirtualKey::None, SUPPORTS_NEGATIVE },
NavCategoryInitializer { ViewMode::Energy, ENERGY_ID, L"Energy", L"CategoryName_Energy", L"\uECAD", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Area, AREA_ID, L"Area", L"CategoryName_Area", L"\uE809", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Speed, SPEED_ID, L"Speed", L"CategoryName_Speed", L"\uEADA", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Time, TIME_ID, L"Time", L"CategoryName_Time", L"\uE917", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Power, POWER_ID, L"Power", L"CategoryName_Power", L"\uE945", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Data, DATA_ID, L"Data", L"CategoryName_Data", L"\uF20F", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Pressure, PRESSURE_ID, L"Pressure", L"CategoryName_Pressure", L"\uEC4A", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY },
NavCategoryInitializer { ViewMode::Angle, ANGLE_ID, L"Angle", L"CategoryName_Angle", L"\uF515", CategoryGroupType::Converter, MyVirtualKey::None, POSITIVE_ONLY }
};
static constexpr array<const NavCategoryInitializer, 18> s_categoryManifest = { NavCategoryInitializer{ ViewMode::Standard,
STANDARD_ID,
L"Standard",
L"StandardMode",
L"\uE8EF",
CategoryGroupType::Calculator,
MyVirtualKey::Number1,
SUPPORTS_ALL },
NavCategoryInitializer{ ViewMode::Graphing,
GRAPHING_ID,
L"Graphing",
L"GraphingCalculatorMode",
L"\uF770",
CategoryGroupType::Calculator,
MyVirtualKey::Number5,
SUPPORTS_ALL },
NavCategoryInitializer{ ViewMode::Scientific,
SCIENTIFIC_ID,
L"Scientific",
L"ScientificMode",
L"\uF196",
CategoryGroupType::Calculator,
MyVirtualKey::Number2,
SUPPORTS_ALL },
NavCategoryInitializer{ ViewMode::Programmer,
PROGRAMMER_ID,
L"Programmer",
L"ProgrammerMode",
L"\uECCE",
CategoryGroupType::Calculator,
MyVirtualKey::Number3,
SUPPORTS_ALL },
NavCategoryInitializer{ ViewMode::Date,
DATE_ID,
L"Date",
L"DateCalculationMode",
L"\uE787",
CategoryGroupType::Calculator,
MyVirtualKey::Number4,
SUPPORTS_ALL },
NavCategoryInitializer{ ViewMode::Currency,
CURRENCY_ID,
L"Currency",
L"CategoryName_Currency",
L"\uEB0D",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Volume,
VOLUME_ID,
L"Volume",
L"CategoryName_Volume",
L"\uF1AA",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Length,
LENGTH_ID,
L"Length",
L"CategoryName_Length",
L"\uECC6",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Weight,
WEIGHT_ID,
L"Weight and Mass",
L"CategoryName_Weight",
L"\uF4C1",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Temperature,
TEMPERATURE_ID,
L"Temperature",
L"CategoryName_Temperature",
L"\uE7A3",
CategoryGroupType::Converter,
MyVirtualKey::None,
SUPPORTS_NEGATIVE },
NavCategoryInitializer{ ViewMode::Energy,
ENERGY_ID,
L"Energy",
L"CategoryName_Energy",
L"\uECAD",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Area,
AREA_ID,
L"Area",
L"CategoryName_Area",
L"\uE809",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Speed,
SPEED_ID,
L"Speed",
L"CategoryName_Speed",
L"\uEADA",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Time,
TIME_ID,
L"Time",
L"CategoryName_Time",
L"\uE917",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Power,
POWER_ID,
L"Power",
L"CategoryName_Power",
L"\uE945",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Data,
DATA_ID,
L"Data",
L"CategoryName_Data",
L"\uF20F",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Pressure,
PRESSURE_ID,
L"Pressure",
L"CategoryName_Pressure",
L"\uEC4A",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY },
NavCategoryInitializer{ ViewMode::Angle,
ANGLE_ID,
L"Angle",
L"CategoryName_Angle",
L"\uF515",
CategoryGroupType::Converter,
MyVirtualKey::None,
POSITIVE_ONLY } };
// This function should only be used when storing the mode to app data.
int NavCategory::Serialize(ViewMode mode)

Разница между файлами не показана из-за своего большого размера Загрузить разницу

Просмотреть файл

@ -6,6 +6,7 @@
#include "CalcManager/Command.h"
#include "TraceActivity.h"
#include "NavCategory.h"
#include "CalculatorButtonUser.h"
static const int maxFunctionSize = (int)CalculationManager::Command::CommandBINEDITEND;
@ -13,19 +14,17 @@ static const int maxFunctionSize = (int)CalculationManager::Command::CommandBINE
// This class implements a singleton model ensure that only one instance is created.
namespace CalculatorApp
{
struct FuncLog
struct ButtonLog
{
public:
int count;
std::wstring funcName;
FuncLog()
CalculatorApp::NumbersAndOperatorsEnum button;
CalculatorApp::Common::ViewMode mode;
ButtonLog(CalculatorApp::NumbersAndOperatorsEnum btn, CalculatorApp::Common::ViewMode vMode)
{
count = 0;
}
FuncLog(std::wstring fName)
{
funcName = fName;
count = 0;
button = btn;
mode = vMode;
count = 1;
}
};
@ -38,123 +37,46 @@ namespace CalculatorApp
static TraceLogger& GetInstance();
bool GetTraceLoggingProviderEnabled() const;
void LogAppLaunchStart();
void LogAppLaunchComplete();
void LogAppResumeComplete();
void LogOnAppLaunch(std::wstring_view previousExecutionState) const;
void LogMemoryClearAll(int);
void LogBitFlipPaneClicked() const;
void LogBitFlipUsed() const;
void LogHistoryBodyOpened() const;
void LogHistoryItemLoadBegin() const;
void LogHistoryItemLoadEnd(unsigned int) const;
void LogHistoryFlyoutOpenBegin(unsigned int) const;
void LogHistoryFlyoutOpenEnd(int) const;
void LogCalculatorModeViewed(CalculatorApp::Common::ViewMode, int);
void LogDateCalculatorModeViewed(CalculatorApp::Common::ViewMode, int);
void LogConverterModeViewed(CalculatorApp::Common::ViewMode, int);
void LogModeChangeBegin(CalculatorApp::Common::ViewMode, CalculatorApp::Common::ViewMode, int);
void LogModeChangeEnd(CalculatorApp::Common::ViewMode, int) const;
void LogClearHistory() const;
void InsertIntoMemoryMap(int, bool, bool, bool);
void UpdateMemoryMap(int, int, bool, bool, bool);
void DeleteFromMemoryMap(int, int);
void LogMemoryUsed(int, unsigned int, bool, bool, bool, unsigned int) const;
void LogMultipleMemoryUsed(unsigned int, unsigned int) const;
void LogSingleMemoryUsed(unsigned int) const;
void LogSharedMemoryUsed(std::wstring_view, std::wstring_view, unsigned int) const;
void LogMemoryBodyOpened() const;
void LogMemoryFlyoutOpenBegin(unsigned int) const;
void LogDebug(std::wstring_view debugData);
void LogMemoryFlyoutOpenEnd(unsigned int) const;
void LogInvalidPastedInputOccurred(std::wstring_view reason, CalculatorApp::Common::ViewMode mode, int ProgrammerNumberBase, int bitLengthType);
void LogValidInputPasted(CalculatorApp::Common::ViewMode mode) const;
void UpdateFunctionUsage(int func);
void LogFunctionUsage(int);
void InitFunctionLogArray();
void LogBitLengthButtonUsed(int windowId);
void LogRadixButtonUsed(int windowId);
void LogAngleButtonUsed(int windowId);
void LogHypButtonUsed(int windowId);
void LogNewWindowCreationBegin(int windowId);
void LogNewWindowCreationEnd(int windowId);
void LogError(std::wstring_view errorString);
void LogPrelaunchedAppActivatedByUser();
void LogAppPrelaunchedBySystem();
void UpdateWindowCount(size_t windowCount);
bool UpdateWindowIdLog(int windowId);
void LogMaxWindowCount();
void LogWindowActivated() const;
void LogWindowLaunched() const;
void LogUserRequestedRefreshFailed() const;
void LogConversionResult(std::wstring_view fromValue, std::wstring_view fromUnit, std::wstring_view toValue, std::wstring_view toUnit) const;
void LogAboutFlyoutOpened() const;
void LogModeChange(CalculatorApp::Common::ViewMode mode) const;
void LogHistoryItemLoad(CalculatorApp::Common::ViewMode mode, int historyListSize, int loadedIndex) const;
void LogMemoryItemLoad(CalculatorApp::Common::ViewMode mode, int memoryListSize, int loadedIndex) const;
void UpdateButtonUsage(CalculatorApp::NumbersAndOperatorsEnum button, CalculatorApp::Common::ViewMode mode);
void LogButtonUsage();
void LogDateCalculationModeUsed(bool AddSubtractMode);
void UpdateWindowCount(size_t windowCount = 0);
bool IsWindowIdInLog(int windowId);
void LogVisualStateChanged(CalculatorApp::Common::ViewMode mode, std::wstring_view state, bool isAlwaysOnTop = false) const;
void LogWindowCreated(CalculatorApp::Common::ViewMode mode, int windowId);
void LogConverterInputReceived(CalculatorApp::Common::ViewMode mode) const;
void LogNavBarOpened() const;
void LogViewClosingTelemetry(int);
void LogCoreWindowWasNull() const;
// Trace methods for Date Calculator usage
void LogDateDifferenceModeUsed(int windowId);
void LogDateAddSubtractModeUsed(int windowId, bool isAddMode);
void
LogDateClippedTimeDifferenceFound(winrt::Windows::Globalization::Calendar const& today, winrt::Windows::Foundation::DateTime const& clippedTime) const;
void LogStandardException(std::wstring_view functionName, _In_ const std::exception& e) const;
void LogWinRTException(std::wstring_view functionName, _In_ winrt::hresult_error const& e) const;
void LogPlatformException(std::wstring_view functionName, _In_ Platform::Exception ^ e) const;
void LogError(CalculatorApp::Common::ViewMode mode, std::wstring_view functionName, std::wstring_view errorString);
void LogStandardException(CalculatorApp::Common::ViewMode mode, std::wstring_view functionName, _In_ const std::exception& e) const;
void LogWinRTException(CalculatorApp::Common::ViewMode mode, std::wstring_view functionName, _In_ winrt::hresult_error const& e) const;
void LogPlatformException(CalculatorApp::Common::ViewMode mode, std::wstring_view functionName, _In_ Platform::Exception ^ e) const;
void LogInputPasted(CalculatorApp::Common::ViewMode mode) const;
private:
// Create an instance of TraceLogger
TraceLogger();
// Any new Log method should
// a) decide the level of logging. This will help us in limiting recording of events only up to a certain level. See this link for guidance
// https://msdn.microsoft.com/en-us/library/windows/desktop/aa363742(v=vs.85).aspx We're using Verbose level for events that are called frequently and
// needed only for debugging or capturing perf for specific scenarios b) should decide whether or not to log to telemetry and pass
// TraceLoggingKeyword(MICROSOFT_KEYWORD_TELEMETRY) accordingly c) Should accept a variable number of additional data arguments if needed
void LogTelemetryEvent(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
void LogMeasureEvent(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
void LogCriticalDataEvent(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
void LogPerformanceEvent(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
void LogInfoEvent(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
// As mentioned in Microsoft's Privacy Statement(https://privacy.microsoft.com/en-US/privacystatement#maindiagnosticsmodule),
// sampling is involved in Microsoft's diagnostic data collection process.
// These keywords provide additional input into how frequently an event might be sampled.
// The lower the level of the keyword, the higher the possibility that the corresponding event may be sampled.
void LogLevel1Event(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
void LogLevel2Event(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
void LogLevel3Event(std::wstring_view eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
std::unique_ptr<TraceActivity> CreateTraceActivity(std::wstring_view activityName, winrt::Windows::Foundation::Diagnostics::LoggingFields fields) const;
winrt::Windows::Foundation::Diagnostics::LoggingChannel g_calculatorProvider;
bool isSizeChangeLogged = false;
bool isHideIfShownLogged = false;
bool isSizeChangedFirstTime = true; // to track the first size changed event which is fired on the launch of app
bool isAutoConversionBeginLoggedInSession = false;
bool isAutoConversionEndLoggedInSession = false;
bool angleButtonLoggedInSession = false;
bool radixButtonLoggedInSession = false;
bool bitLengthButtonLoggedInSession = false;
std::vector<ButtonLog> buttonLog;
std::vector<int> windowIdLog;
GUID sessionGuid;
CalculatorApp::Common::ViewMode currentMode = CalculatorApp::Common::ViewMode::None;
std::vector<FuncLog> funcLog;
int functionCount = 0;
bool isHypButtonLogged = false;
bool isAngleButtonInitialized = false;
unsigned int findIndex[maxFunctionSize] = { 0 };
bool GetIndex(int& index);
std::wstring GetProgrammerType(int index);
size_t maxWindowCount = 0;
bool isAppLaunchBeginLogged = false;
bool isAppLaunchEndLogged = false;
std::map<int, int> bitLengthButtonUsage;
std::map<int, int> angleButtonUsage;
std::map<int, int> radixButtonUsage;
std::map<int, bool> windowIdLog;
// Private variables for Date Calculator usage
bool m_dateDiffUsageLoggedInSession = false;
bool m_dateAddUsageLoggedInSession = false;
bool m_dateSubtractUsageLoggedInSession = false;
std::map<int, int> m_dateAddModeUsage;
std::map<int, int> m_dateSubtractModeUsage;
size_t windowLaunchCount = 0;
size_t currentWindowCount = 0;
winrt::Windows::Foundation::Diagnostics::LoggingActivity m_appLaunchActivity;
};

Просмотреть файл

@ -416,8 +416,12 @@ namespace Utils
Windows::Foundation::DateTime GetUniversalSystemTime();
bool IsDateTimeOlderThan(Windows::Foundation::DateTime dateTime, const long long duration);
concurrency::task<void> WriteFileToFolder(Windows::Storage::IStorageFolder^ folder, Platform::String^ fileName, Platform::String^ contents, Windows::Storage::CreationCollisionOption collisionOption);
concurrency::task<Platform::String^> ReadFileFromFolder(Windows::Storage::IStorageFolder^ folder, Platform::String^ fileName);
concurrency::task<void> WriteFileToFolder(
Windows::Storage::IStorageFolder ^ folder,
Platform::String ^ fileName,
Platform::String ^ contents,
Windows::Storage::CreationCollisionOption collisionOption);
concurrency::task<Platform::String ^> ReadFileFromFolder(Windows::Storage::IStorageFolder ^ folder, Platform::String ^ fileName);
bool AreColorsEqual(const Windows::UI::Color& color1, const Windows::UI::Color& color2);

Просмотреть файл

@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#include "pch.h"
@ -39,7 +39,9 @@ static constexpr auto CURRENCY_UNIT_TO_KEY = L"CURRENCY_UNIT_TO_KEY";
static constexpr long long DAY_DURATION = 1LL * 60 * 60 * 24 * 10000000;
static constexpr long long WEEK_DURATION = DAY_DURATION * 7;
static constexpr int FORMATTER_DIGIT_COUNT = 4;
static constexpr int FORMATTER_RATE_FRACTION_PADDING = 2;
static constexpr int FORMATTER_RATE_MIN_DECIMALS = 4;
static constexpr int FORMATTER_RATE_MIN_SIGNIFICANT_DECIMALS = 4;
static constexpr auto CACHE_TIMESTAMP_KEY = L"CURRENCY_CONVERTER_TIMESTAMP";
static constexpr auto CACHE_LANGCODE_KEY = L"CURRENCY_CONVERTER_LANGCODE";
@ -128,7 +130,7 @@ CurrencyDataLoader::CurrencyDataLoader(_In_ unique_ptr<ICurrencyHttpClient> clie
m_ratioFormatter = localizationService->GetRegionalSettingsAwareDecimalFormatter();
m_ratioFormatter->IsGrouped = true;
m_ratioFormatter->IsDecimalPointAlwaysDisplayed = true;
m_ratioFormatter->FractionDigits = FORMATTER_DIGIT_COUNT;
m_ratioFormatter->FractionDigits = FORMATTER_RATE_FRACTION_PADDING;
m_ratioFormat = AppResourceProvider::GetInstance().GetResourceString(L"CurrencyFromToRatioFormat")->Data();
m_timestampFormat = AppResourceProvider::GetInstance().GetResourceString(L"CurrencyTimestampFormat")->Data();
@ -267,6 +269,23 @@ pair<wstring, wstring> CurrencyDataLoader::GetCurrencySymbols(const UCM::Unit& u
return make_pair(symbol1, symbol2);
}
double CurrencyDataLoader::RoundCurrencyRatio(double ratio)
{
// Compute how many decimals we need to display two meaningful digits at minimum
// For example: 0.00000000342334 -> 0.000000003423, 0.000212 -> 0.000212
int numberDecimals = FORMATTER_RATE_MIN_DECIMALS;
if (ratio < 1)
{
numberDecimals = max(
FORMATTER_RATE_MIN_DECIMALS,
(int)(-log10(ratio)) + FORMATTER_RATE_MIN_SIGNIFICANT_DECIMALS);
}
unsigned long long scale = (unsigned long long)powl(10l, numberDecimals);
return (double)(round(ratio * scale) / scale);
}
pair<wstring, wstring> CurrencyDataLoader::GetCurrencyRatioEquality(_In_ const UCM::Unit& unit1, _In_ const UCM::Unit& unit2)
{
try
@ -279,12 +298,7 @@ pair<wstring, wstring> CurrencyDataLoader::GetCurrencyRatioEquality(_In_ const U
if (iter2 != ratioMap.end())
{
double ratio = (iter2->second).ratio;
// Round the ratio to FORMATTER_DIGIT_COUNT digits using int math.
// Ex: to round 1.23456 to three digits, use
// ((int) 1.23456 * (10^3)) / (10^3)
double scale = pow(10, FORMATTER_DIGIT_COUNT);
double rounded = static_cast<int>(ratio * static_cast<int>(scale)) / scale;
double rounded = RoundCurrencyRatio(ratio);
wstring digitSymbol = wstring{ LocalizationSettings::GetInstance().GetDigitSymbolFromEnUsDigit(L'1') };
wstring roundedFormat = m_ratioFormatter->Format(rounded)->Data();
@ -335,12 +349,12 @@ future<bool> CurrencyDataLoader::TryLoadDataFromCacheAsync()
}
catch (Exception ^ ex)
{
TraceLogger::GetInstance().LogPlatformException(__FUNCTIONW__, ex);
TraceLogger::GetInstance().LogPlatformException(ViewMode::Currency, __FUNCTIONW__, ex);
co_return false;
}
catch (const exception& e)
{
TraceLogger::GetInstance().LogStandardException(__FUNCTIONW__, e);
TraceLogger::GetInstance().LogStandardException(ViewMode::Currency, __FUNCTIONW__, e);
co_return false;
}
catch (...)
@ -445,12 +459,12 @@ future<bool> CurrencyDataLoader::TryLoadDataFromWebAsync()
}
catch (Exception ^ ex)
{
TraceLogger::GetInstance().LogPlatformException(__FUNCTIONW__, ex);
TraceLogger::GetInstance().LogPlatformException(ViewMode::Currency, __FUNCTIONW__, ex);
co_return false;
}
catch (const exception& e)
{
TraceLogger::GetInstance().LogStandardException(__FUNCTIONW__, e);
TraceLogger::GetInstance().LogStandardException(ViewMode::Currency, __FUNCTIONW__, e);
co_return false;
}
catch (...)
@ -466,7 +480,7 @@ future<bool> CurrencyDataLoader::TryLoadDataFromWebOverrideAsync()
if (!didLoad)
{
m_loadStatus = CurrencyLoadStatus::FailedToLoad;
TraceLogger::GetInstance().LogUserRequestedRefreshFailed();
TraceLogger::GetInstance().LogError(ViewMode::Currency, L"CurrencyDataLoader::TryLoadDataFromWebOverrideAsync", L"UserRequestedRefreshFailed");
}
co_return didLoad;
@ -527,8 +541,11 @@ bool CurrencyDataLoader::TryParseStaticData(_In_ String ^ rawJson, _Inout_ vecto
staticData[i] = CurrencyStaticData{ countryCode, countryName, currencyCode, currencyName, currencySymbol };
}
// TODO - MSFT 8533667: this sort will be replaced by a WinRT call to sort localized strings
sort(begin(staticData), end(staticData), [](CurrencyStaticData unit1, CurrencyStaticData unit2) { return unit1.countryName < unit2.countryName; });
auto sortCountryNames = [](const UCM::CurrencyStaticData & s) {
return ref new String(s.countryName.c_str());
};
LocalizationService::GetInstance()->Sort<UCM::CurrencyStaticData>(staticData, sortCountryNames);
return true;
}

Просмотреть файл

@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#pragma once
@ -75,6 +75,7 @@ namespace CalculatorApp
std::pair<std::wstring, std::wstring>
GetCurrencyRatioEquality(_In_ const UnitConversionManager::Unit& unit1, _In_ const UnitConversionManager::Unit& unit2) override;
std::wstring GetCurrencyTimestamp() override;
static double RoundCurrencyRatio(double ratio);
std::future<bool> TryLoadDataFromCacheAsync() override;
std::future<bool> TryLoadDataFromWebAsync() override;

Просмотреть файл

@ -88,9 +88,6 @@ DateCalculatorViewModel::DateCalculatorViewModel()
if (calendar->DayOfWeek != trueDayOfWeek)
{
calendar->SetDateTime(today);
TraceLogger::GetInstance().LogDateClippedTimeDifferenceFound(
from_cx<winrt::Windows::Globalization::Calendar>(calendar),
winrt::Windows::Foundation::DateTime{ winrt::Windows::Foundation::TimeSpan{ clippedTime.UniversalTime } });
}
}

Просмотреть файл

@ -118,6 +118,9 @@ void HistoryViewModel::SetCalculatorDisplay(CalculatorDisplay& calculatorDisplay
void HistoryViewModel::ShowItem(_In_ HistoryItemViewModel ^ e)
{
unsigned int index;
Items->IndexOf(e, &index);
TraceLogger::GetInstance().LogHistoryItemLoad((ViewMode)m_currentMode, ItemSize, (int)(index));
HistoryItemClicked(e);
}
@ -149,7 +152,6 @@ void HistoryViewModel::OnHideCommand(_In_ Platform::Object ^ e)
void HistoryViewModel::OnClearCommand(_In_ Platform::Object ^ e)
{
TraceLogger::GetInstance().LogClearHistory();
if (AreHistoryShortcutsEnabled == true)
{
m_calculatorManager->ClearHistory();

Просмотреть файл

@ -35,8 +35,10 @@ namespace
StringReference IsStandardPropertyName(L"IsStandard");
StringReference IsScientificPropertyName(L"IsScientific");
StringReference IsProgrammerPropertyName(L"IsProgrammer");
StringReference IsAlwaysOnTopPropertyName(L"IsAlwaysOnTop");
StringReference DisplayValuePropertyName(L"DisplayValue");
StringReference CalculationResultAutomationNamePropertyName(L"CalculationResultAutomationName");
StringReference IsBitFlipCheckedPropertyName(L"IsBitFlipChecked");
}
namespace CalculatorResourceKeys
@ -65,6 +67,7 @@ StandardCalculatorViewModel::StandardCalculatorViewModel()
, m_HexDisplayValue(L"0")
, m_BinaryDisplayValue(L"0")
, m_OctalDisplayValue(L"0")
, m_BinaryDigits(ref new Vector<bool>(64, false))
, m_standardCalculatorManager(&m_calculatorDisplay, &m_resourceProvider)
, m_ExpressionTokens(ref new Vector<DisplayExpressionToken ^>())
, m_MemorizedNumbers(ref new Vector<MemoryItemViewModel ^>())
@ -72,10 +75,7 @@ StandardCalculatorViewModel::StandardCalculatorViewModel()
, m_IsFToEChecked(false)
, m_isShiftChecked(false)
, m_IsShiftProgrammerChecked(false)
, m_IsQwordEnabled(true)
, m_IsDwordEnabled(true)
, m_IsWordEnabled(true)
, m_IsByteEnabled(true)
, m_valueBitLength(BitLength::BitLengthQWord)
, m_isBitFlipChecked(false)
, m_isBinaryBitFlippingEnabled(false)
, m_CurrentRadixType(RADIX_TYPE::DEC_RADIX)
@ -201,7 +201,12 @@ void StandardCalculatorViewModel::SetPrimaryDisplay(_In_ wstring const& displayS
// not match what the narrator is saying
m_CalculationResultAutomationName = CalculateNarratorDisplayValue(displayStringValue, localizedDisplayStringValue, isError);
DisplayValue = localizedDisplayStringValue;
AreAlwaysOnTopResultsUpdated = false;
if (DisplayValue != localizedDisplayStringValue)
{
DisplayValue = localizedDisplayStringValue;
AreAlwaysOnTopResultsUpdated = true;
}
IsInError = isError;
@ -414,7 +419,7 @@ void StandardCalculatorViewModel::SetMemorizedNumbers(const vector<wstring>& new
memorySlot->Value = Utils::LRO + ref new String(stringValue.c_str()) + Utils::PDF;
MemorizedNumbers->InsertAt(0, memorySlot);
IsMemoryEmpty = false;
IsMemoryEmpty = IsAlwaysOnTop;
// Update the slot position for the rest of the slots
for (unsigned int i = 1; i < MemorizedNumbers->Size; i++)
@ -599,8 +604,6 @@ void StandardCalculatorViewModel::OnButtonPressed(Object ^ parameter)
NumbersAndOperatorsEnum numOpEnum = CalculatorButtonPressedEventArgs::GetOperationFromCommandParameter(parameter);
Command cmdenum = ConvertToOperatorsEnum(numOpEnum);
TraceLogger::GetInstance().UpdateFunctionUsage((int)numOpEnum);
if (IsInError)
{
m_standardCalculatorManager.SendCommand(Command::CommandCLEAR);
@ -668,31 +671,12 @@ void StandardCalculatorViewModel::OnButtonPressed(Object ^ parameter)
m_isLastOperationHistoryLoad = false;
}
TraceLogger::GetInstance().UpdateButtonUsage(numOpEnum, GetCalculatorMode());
m_standardCalculatorManager.SendCommand(cmdenum);
}
}
}
int StandardCalculatorViewModel::GetBitLengthType()
{
if (IsQwordEnabled)
{
return QwordType;
}
else if (IsDwordEnabled)
{
return DwordType;
}
else if (IsWordEnabled)
{
return WordType;
}
else
{
return ByteType;
}
}
int StandardCalculatorViewModel::GetNumberBase()
{
if (CurrentRadixType == HEX_RADIX)
@ -723,9 +707,10 @@ void StandardCalculatorViewModel::OnCopyCommand(Object ^ parameter)
void StandardCalculatorViewModel::OnPasteCommand(Object ^ parameter)
{
auto that(this);
ViewMode mode;
int NumberBase = -1;
int bitLengthType = -1;
BitLength bitLengthType = BitLength::BitLengthUnknown;
if (IsScientific)
{
mode = ViewMode::Scientific;
@ -734,7 +719,7 @@ void StandardCalculatorViewModel::OnPasteCommand(Object ^ parameter)
{
mode = ViewMode::Programmer;
NumberBase = GetNumberBase();
bitLengthType = GetBitLengthType();
bitLengthType = m_valueBitLength;
}
else
{
@ -748,7 +733,7 @@ void StandardCalculatorViewModel::OnPasteCommand(Object ^ parameter)
// Ensure that the paste happens on the UI thread
CopyPasteManager::GetStringToPaste(mode, NavCategory::GetGroupType(mode), NumberBase, bitLengthType)
.then([this, mode](String ^ pastedString) { OnPaste(pastedString, mode); }, concurrency::task_continuation_context::use_current());
.then([that, mode](String ^ pastedString) { that->OnPaste(pastedString); }, concurrency::task_continuation_context::use_current());
}
CalculationManager::Command StandardCalculatorViewModel::ConvertToOperatorsEnum(NumbersAndOperatorsEnum operation)
@ -756,7 +741,7 @@ CalculationManager::Command StandardCalculatorViewModel::ConvertToOperatorsEnum(
return safe_cast<Command>(operation);
}
void StandardCalculatorViewModel::OnPaste(String ^ pastedString, ViewMode mode)
void StandardCalculatorViewModel::OnPaste(String ^ pastedString)
{
// If pastedString is invalid("NoOp") then display pasteError else process the string
if (pastedString == StringReference(CopyPasteManager::PasteErrorString))
@ -765,7 +750,7 @@ void StandardCalculatorViewModel::OnPaste(String ^ pastedString, ViewMode mode)
return;
}
TraceLogger::GetInstance().LogValidInputPasted(mode);
TraceLogger::GetInstance().LogInputPasted(GetCalculatorMode());
bool isFirstLegalChar = true;
m_standardCalculatorManager.SendCommand(Command::CommandCENTR);
bool sendNegate = false;
@ -884,7 +869,7 @@ void StandardCalculatorViewModel::OnPaste(String ^ pastedString, ViewMode mode)
// Handle exponent and exponent sign (...e+... or ...e-... or ...e...)
if (mappedNumOp == NumbersAndOperatorsEnum::Exp)
{
//Check the following item
// Check the following item
switch (MapCharacterToButtonId(*(it + 1), canSendNegate))
{
case NumbersAndOperatorsEnum::Subtract:
@ -896,7 +881,7 @@ void StandardCalculatorViewModel::OnPaste(String ^ pastedString, ViewMode mode)
break;
case NumbersAndOperatorsEnum::Add:
{
//Nothing to do, skip to the next item
// Nothing to do, skip to the next item
++it;
}
break;
@ -911,8 +896,7 @@ void StandardCalculatorViewModel::OnClearMemoryCommand(Object ^ parameter)
{
m_standardCalculatorManager.MemorizedNumberClearAll();
int windowId = Utils::GetWindowId();
TraceLogger::GetInstance().LogMemoryClearAll(windowId);
TraceLogger::GetInstance().UpdateButtonUsage(NumbersAndOperatorsEnum::MemoryClear, GetCalculatorMode());
String ^ announcement = LocalizationStringUtil::GetLocalizedNarratorAnnouncement(CalculatorResourceKeys::MemoryCleared, m_localizedMemoryCleared);
Announcement = CalculatorAnnouncement::GetMemoryClearedAnnouncement(announcement);
@ -1046,8 +1030,7 @@ void StandardCalculatorViewModel::OnMemoryButtonPressed()
{
m_standardCalculatorManager.MemorizeNumber();
int windowId = Utils::GetWindowId();
TraceLogger::GetInstance().InsertIntoMemoryMap(windowId, IsStandard, IsScientific, IsProgrammer);
TraceLogger::GetInstance().UpdateButtonUsage(NumbersAndOperatorsEnum::Memory, GetCalculatorMode());
String ^ announcement = LocalizationStringUtil::GetLocalizedNarratorAnnouncement(
CalculatorResourceKeys::MemorySave, m_localizedMemorySavedAutomationFormat, m_DisplayValue->Data());
@ -1079,49 +1062,31 @@ void StandardCalculatorViewModel::OnMemoryItemPressed(Object ^ memoryItemPositio
auto boxedPosition = safe_cast<Box<int> ^>(memoryItemPosition);
m_standardCalculatorManager.MemorizedNumberLoad(boxedPosition->Value);
HideMemoryClicked();
int windowId = Utils::GetWindowId();
TraceLogger::GetInstance().LogMemoryUsed(windowId, boxedPosition->Value, IsStandard, IsScientific, IsProgrammer, MemorizedNumbers->Size);
auto mode = IsStandard ? ViewMode::Standard : IsScientific ? ViewMode::Scientific : ViewMode::Programmer;
TraceLogger::GetInstance().LogMemoryItemLoad(mode, MemorizedNumbers->Size, boxedPosition->Value);
}
}
void StandardCalculatorViewModel::OnMemoryAdd(Object ^ memoryItemPosition)
{
// M+ will add display to memorylist if memory list is empty.
int windowId = Utils::GetWindowId();
if (MemorizedNumbers)
{
auto boxedPosition = safe_cast<Box<int> ^>(memoryItemPosition);
if (MemorizedNumbers->Size > 0)
{
TraceLogger::GetInstance().LogMemoryUsed(windowId, boxedPosition->Value, IsStandard, IsScientific, IsProgrammer, MemorizedNumbers->Size);
TraceLogger::GetInstance().UpdateMemoryMap(windowId, boxedPosition->Value, IsStandard, IsScientific, IsProgrammer);
}
else
{
TraceLogger::GetInstance().InsertIntoMemoryMap(windowId, IsStandard, IsScientific, IsProgrammer);
}
TraceLogger::GetInstance().UpdateButtonUsage(NumbersAndOperatorsEnum::MemoryAdd, GetCalculatorMode());
m_standardCalculatorManager.MemorizedNumberAdd(boxedPosition->Value);
}
}
void StandardCalculatorViewModel::OnMemorySubtract(Object ^ memoryItemPosition)
{
int windowId = Utils::GetWindowId();
// M- will add negative of displayed number to memorylist if memory list is empty.
if (MemorizedNumbers)
{
auto boxedPosition = safe_cast<Box<int> ^>(memoryItemPosition);
if (MemorizedNumbers->Size > 0)
{
TraceLogger::GetInstance().LogMemoryUsed(windowId, boxedPosition->Value, IsStandard, IsScientific, IsProgrammer, MemorizedNumbers->Size);
TraceLogger::GetInstance().UpdateMemoryMap(windowId, boxedPosition->Value, IsStandard, IsScientific, IsProgrammer);
}
else
{
TraceLogger::GetInstance().InsertIntoMemoryMap(windowId, IsStandard, IsScientific, IsProgrammer);
}
TraceLogger::GetInstance().UpdateButtonUsage(NumbersAndOperatorsEnum::MemorySubtract, GetCalculatorMode());
m_standardCalculatorManager.MemorizedNumberSubtract(boxedPosition->Value);
}
}
@ -1130,7 +1095,6 @@ void StandardCalculatorViewModel::OnMemoryClear(_In_ Object ^ memoryItemPosition
{
if (MemorizedNumbers && MemorizedNumbers->Size > 0)
{
int windowId = Utils::GetWindowId();
auto boxedPosition = safe_cast<Box<int> ^>(memoryItemPosition);
if (boxedPosition->Value >= 0)
@ -1148,9 +1112,7 @@ void StandardCalculatorViewModel::OnMemoryClear(_In_ Object ^ memoryItemPosition
{
IsMemoryEmpty = true;
}
TraceLogger::GetInstance().LogMemoryUsed(windowId, boxedPosition->Value, IsStandard, IsScientific, IsProgrammer, MemorizedNumbers->Size);
TraceLogger::GetInstance().DeleteFromMemoryMap(windowId, boxedPosition->Value);
TraceLogger::GetInstance().UpdateButtonUsage(NumbersAndOperatorsEnum::MemoryClear, GetCalculatorMode());
wstring localizedIndex = to_wstring(boxedPosition->Value + 1);
LocalizationSettings::GetInstance().LocalizeDisplayValue(&localizedIndex);
@ -1191,6 +1153,11 @@ void StandardCalculatorViewModel::OnPropertyChanged(String ^ propertyname)
RaisePropertyChanged(CalculationResultAutomationNamePropertyName);
Announcement = GetDisplayUpdatedNarratorAnnouncement();
}
else if (propertyname == IsBitFlipCheckedPropertyName)
{
TraceLogger::GetInstance().UpdateButtonUsage(
IsBitFlipChecked ? NumbersAndOperatorsEnum::BitflipButton : NumbersAndOperatorsEnum::FullKeypadButton, ViewMode::Programmer);
}
}
void StandardCalculatorViewModel::SetCalculatorType(ViewMode targetState)
@ -1223,7 +1190,7 @@ void StandardCalculatorViewModel::SetCalculatorType(ViewMode targetState)
}
}
String^ StandardCalculatorViewModel::GetRawDisplayValue()
String ^ StandardCalculatorViewModel::GetRawDisplayValue()
{
if (IsInError)
{
@ -1654,6 +1621,7 @@ wstring StandardCalculatorViewModel::AddPadding(wstring binaryString)
void StandardCalculatorViewModel::UpdateProgrammerPanelDisplay()
{
constexpr int32_t precision = 64;
wstring hexDisplayString;
wstring decimalDisplayString;
wstring octalDisplayString;
@ -1661,8 +1629,7 @@ void StandardCalculatorViewModel::UpdateProgrammerPanelDisplay()
if (!IsInError)
{
// we want the precision to be set to maximum value so that the autoconversions result as desired
int32_t precision = 64;
if (m_standardCalculatorManager.GetResultForRadix(16, precision) == L"")
if ((hexDisplayString = m_standardCalculatorManager.GetResultForRadix(16, precision, true)) == L"")
{
hexDisplayString = DisplayValue->Data();
decimalDisplayString = DisplayValue->Data();
@ -1671,10 +1638,9 @@ void StandardCalculatorViewModel::UpdateProgrammerPanelDisplay()
}
else
{
hexDisplayString = m_standardCalculatorManager.GetResultForRadix(16, precision);
decimalDisplayString = m_standardCalculatorManager.GetResultForRadix(10, precision);
octalDisplayString = m_standardCalculatorManager.GetResultForRadix(8, precision);
binaryDisplayString = m_standardCalculatorManager.GetResultForRadix(2, precision);
decimalDisplayString = m_standardCalculatorManager.GetResultForRadix(10, precision, true);
octalDisplayString = m_standardCalculatorManager.GetResultForRadix(8, precision, true);
binaryDisplayString = m_standardCalculatorManager.GetResultForRadix(2, precision, true);
}
}
const auto& localizer = LocalizationSettings::GetInstance();
@ -1693,6 +1659,17 @@ void StandardCalculatorViewModel::UpdateProgrammerPanelDisplay()
DecDisplayValue_AutomationName = GetLocalizedStringFormat(m_localizedDecimalAutomationFormat, DecimalDisplayValue);
OctDisplayValue_AutomationName = GetLocalizedStringFormat(m_localizedOctalAutomationFormat, GetNarratorStringReadRawNumbers(OctalDisplayValue));
BinDisplayValue_AutomationName = GetLocalizedStringFormat(m_localizedBinaryAutomationFormat, GetNarratorStringReadRawNumbers(BinaryDisplayValue));
auto binaryValueArray = ref new Vector<bool>(64, false);
auto binaryValue = m_standardCalculatorManager.GetResultForRadix(2, precision, false);
int i = 0;
// To get bit 0, grab from opposite end of string.
for (std::wstring::reverse_iterator it = binaryValue.rbegin(); it != binaryValue.rend(); ++it)
{
binaryValueArray->SetAt(i++, *it == L'1');
}
BinaryDigits = binaryValueArray;
}
void StandardCalculatorViewModel::SwitchAngleType(NumbersAndOperatorsEnum num)
@ -1884,3 +1861,44 @@ NarratorAnnouncement ^ StandardCalculatorViewModel::GetDisplayUpdatedNarratorAnn
return CalculatorAnnouncement::GetDisplayUpdatedAnnouncement(announcement);
}
ViewMode StandardCalculatorViewModel::GetCalculatorMode()
{
if (IsStandard)
{
return ViewMode::Standard;
}
else if (IsScientific)
{
return ViewMode::Scientific;
}
return ViewMode::Programmer;
}
void StandardCalculatorViewModel::ValueBitLength::set(CalculatorApp::Common::BitLength value)
{
if (m_valueBitLength != value)
{
m_valueBitLength = value;
RaisePropertyChanged(L"ValueBitLength");
switch (value)
{
case BitLength::BitLengthQWord:
ButtonPressed->Execute(NumbersAndOperatorsEnum::Qword);
break;
case BitLength::BitLengthDWord:
ButtonPressed->Execute(NumbersAndOperatorsEnum::Dword);
break;
case BitLength::BitLengthWord:
ButtonPressed->Execute(NumbersAndOperatorsEnum::Word);
break;
case BitLength::BitLengthByte:
ButtonPressed->Execute(NumbersAndOperatorsEnum::Byte);
break;
}
// update memory list according to bit length
SetMemorizedNumbersString();
}
}

Просмотреть файл

@ -9,6 +9,7 @@
#include "Common/CalculatorButtonUser.h"
#include "HistoryViewModel.h"
#include "MemoryItemViewModel.h"
#include "Common/BitLength.h"
namespace CalculatorFunctionalTests
{
@ -40,7 +41,6 @@ namespace CalculatorApp
StandardCalculatorViewModel();
void UpdateOperand(int pos, Platform::String ^ text);
void UpdatecommandsInRecordingMode();
int GetBitLengthType();
int GetNumberBase();
OBSERVABLE_OBJECT_CALLBACK(OnPropertyChanged);
@ -54,6 +54,7 @@ namespace CalculatorApp
OBSERVABLE_PROPERTY_RW(Platform::String ^, HexDisplayValue);
OBSERVABLE_PROPERTY_RW(Platform::String ^, OctalDisplayValue);
OBSERVABLE_NAMED_PROPERTY_RW(Platform::String ^, BinaryDisplayValue);
OBSERVABLE_NAMED_PROPERTY_R(Windows::Foundation::Collections::IVector<bool> ^, BinaryDigits);
OBSERVABLE_PROPERTY_RW(Platform::String ^, HexDisplayValue_AutomationName);
OBSERVABLE_PROPERTY_RW(Platform::String ^, DecDisplayValue_AutomationName);
OBSERVABLE_PROPERTY_RW(Platform::String ^, OctDisplayValue_AutomationName);
@ -72,12 +73,9 @@ namespace CalculatorApp
OBSERVABLE_PROPERTY_RW(Platform::String ^, CalculationResultAutomationName);
OBSERVABLE_PROPERTY_RW(Platform::String ^, CalculationExpressionAutomationName);
OBSERVABLE_PROPERTY_RW(bool, IsShiftProgrammerChecked);
OBSERVABLE_PROPERTY_RW(bool, IsQwordEnabled);
OBSERVABLE_PROPERTY_RW(bool, IsDwordEnabled);
OBSERVABLE_PROPERTY_RW(bool, IsWordEnabled);
OBSERVABLE_PROPERTY_RW(bool, IsByteEnabled);
OBSERVABLE_PROPERTY_RW(int, CurrentRadixType);
OBSERVABLE_PROPERTY_RW(bool, AreTokensUpdated);
OBSERVABLE_PROPERTY_RW(bool, AreAlwaysOnTopResultsUpdated);
OBSERVABLE_PROPERTY_RW(bool, AreHistoryShortcutsEnabled);
OBSERVABLE_PROPERTY_RW(bool, AreProgrammerRadixOperatorsEnabled);
OBSERVABLE_PROPERTY_RW(CalculatorApp::Common::Automation::NarratorAnnouncement ^, Announcement);
@ -127,6 +125,13 @@ namespace CalculatorApp
}
}
}
static property Platform::String ^ IsBitFlipCheckedPropertyName
{
Platform::String ^ get()
{
return Platform::StringReference(L"IsBitFlipChecked");
}
}
property bool IsBinaryBitFlippingEnabled
{
@ -144,6 +149,15 @@ namespace CalculatorApp
}
}
property CalculatorApp::Common::BitLength ValueBitLength
{
CalculatorApp::Common::BitLength get()
{
return m_valueBitLength;
}
void set(CalculatorApp::Common::BitLength value);
}
property bool IsStandard
{
bool get()
@ -212,6 +226,29 @@ namespace CalculatorApp
}
}
}
static property Platform::String ^ IsProgrammerPropertyName
{
Platform::String ^ get()
{
return Platform::StringReference(L"IsProgrammer");
}
}
property bool IsAlwaysOnTop
{
bool get()
{
return m_isAlwaysOnTop;
}
void set(bool value)
{
if (m_isAlwaysOnTop != value)
{
m_isAlwaysOnTop = value;
RaisePropertyChanged(L"IsAlwaysOnTop");
}
}
}
property bool IsEditingEnabled
{
@ -317,7 +354,7 @@ namespace CalculatorApp
}
}
internal : void OnPaste(Platform::String ^ pastedString, CalculatorApp::Common::ViewMode mode);
internal : void OnPaste(Platform::String ^ pastedString);
void OnCopyCommand(Platform::Object ^ parameter);
void OnPasteCommand(Platform::Object ^ parameter);
@ -348,7 +385,6 @@ namespace CalculatorApp
void OnBinaryOperatorReceived();
void OnMemoryItemChanged(unsigned int indexOfMemory);
Platform::String ^ GetLocalizedStringFormat(Platform::String ^ format, Platform::String ^ displayValue);
void OnPropertyChanged(Platform::String ^ propertyname);
void SetCalculatorType(CalculatorApp::Common::ViewMode targetState);
@ -407,6 +443,7 @@ namespace CalculatorApp
bool m_isStandard;
bool m_isScientific;
bool m_isProgrammer;
bool m_isAlwaysOnTop;
bool m_isBinaryBitFlippingEnabled;
bool m_isBitFlipChecked;
bool m_isShiftChecked;
@ -416,6 +453,7 @@ namespace CalculatorApp
bool m_operandUpdated;
bool m_completeTextSelection;
bool m_isLastOperationHistoryLoad;
CalculatorApp::Common::BitLength m_valueBitLength;
Platform::String ^ m_selectedExpressionLastData;
Common::DisplayExpressionToken ^ m_selectedExpressionToken;
@ -451,6 +489,8 @@ namespace CalculatorApp
bool IsViewPinned();
void SetViewPinnedState(bool pinned);
CalculatorApp::Common::ViewMode GetCalculatorMode();
friend class CalculatorDisplay;
friend class CalculatorFunctionalTests::HistoryTests;
friend class CalculatorUnitTests::MultiWindowUnitTests;

Просмотреть файл

@ -148,7 +148,6 @@ UnitConverterViewModel::UnitConverterViewModel(const shared_ptr<UCM::IUnitConver
Unit2AutomationName = m_localizedOutputUnitName;
IsDecimalEnabled = true;
m_IsFirstTime = true;
m_model->Initialize();
PopulateData();
}
@ -156,7 +155,6 @@ UnitConverterViewModel::UnitConverterViewModel(const shared_ptr<UCM::IUnitConver
void UnitConverterViewModel::ResetView()
{
m_model->SendCommand(UCM::Command::Reset);
m_IsFirstTime = true;
OnCategoryChanged(nullptr);
}
@ -239,15 +237,8 @@ void UnitConverterViewModel::OnUnitChanged(Object ^ parameter)
// End timer to show results immediately
m_supplementaryResultsTimer->Cancel();
}
if (!m_IsFirstTime)
{
SaveUserPreferences();
}
else
{
RestoreUserPreferences();
m_IsFirstTime = false;
}
SaveUserPreferences();
}
void UnitConverterViewModel::OnSwitchActive(Platform::Object ^ unused)
@ -502,6 +493,8 @@ void UnitConverterViewModel::OnButtonPressed(Platform::Object ^ parameter)
}
m_model->SendCommand(command);
TraceLogger::GetInstance().LogConverterInputReceived(Mode);
}
void UnitConverterViewModel::OnCopyCommand(Platform::Object ^ parameter)
@ -523,7 +516,7 @@ void UnitConverterViewModel::OnPasteCommand(Platform::Object ^ parameter)
// EventWriteClipboardPaste_Start();
// Any converter ViewMode is fine here.
CopyPasteManager::GetStringToPaste(m_Mode, NavCategory::GetGroupType(m_Mode))
.then([this](String ^ pastedString) { OnPaste(pastedString, m_Mode); }, concurrency::task_continuation_context::use_current());
.then([this](String ^ pastedString) { OnPaste(pastedString); }, concurrency::task_continuation_context::use_current());
}
void UnitConverterViewModel::InitializeView()
@ -882,7 +875,7 @@ NumbersAndOperatorsEnum UnitConverterViewModel::MapCharacterToButtonId(const wch
return mappedValue;
}
void UnitConverterViewModel::OnPaste(String ^ stringToPaste, ViewMode mode)
void UnitConverterViewModel::OnPaste(String ^ stringToPaste)
{
// If pastedString is invalid("NoOp") then display pasteError else process the string
if (stringToPaste == StringReference(CopyPasteManager::PasteErrorString))
@ -891,7 +884,7 @@ void UnitConverterViewModel::OnPaste(String ^ stringToPaste, ViewMode mode)
return;
}
TraceLogger::GetInstance().LogValidInputPasted(mode);
TraceLogger::GetInstance().LogInputPasted(Mode);
bool isFirstLegalChar = true;
bool sendNegate = false;
wstring accumulation = L"";
@ -1014,7 +1007,6 @@ void UnitConverterViewModel::StartConversionResultTimer()
{
String ^ valueFrom = m_Value1Active ? m_Value1 : m_Value2;
String ^ valueTo = m_Value1Active ? m_Value2 : m_Value1;
TraceLogger::GetInstance().LogConversionResult(valueFrom->Data(), UnitFrom->ToString()->Data(), valueTo->Data(), UnitTo->ToString()->Data());
}
});
}

Просмотреть файл

@ -204,7 +204,7 @@ namespace CalculatorApp
NumbersAndOperatorsEnum MapCharacterToButtonId(const wchar_t ch, bool& canSendNegate);
void DisplayPasteError();
void OnValueActivated(IActivatable ^ control);
void OnPaste(Platform::String ^ stringToPaste, CalculatorApp::Common::ViewMode mode);
void OnPaste(Platform::String ^ stringToPaste);
void OnCopyCommand(Platform::Object ^ parameter);
void OnPasteCommand(Platform::Object ^ parameter);
@ -311,8 +311,6 @@ namespace CalculatorApp
std::wstring m_valueFromUnlocalized;
std::wstring m_valueToUnlocalized;
bool m_relocalizeStringOnSwitch;
// For Saving the User Preferences only if the Unit converter ViewModel is initialised for the first time
bool m_IsFirstTime;
Platform::String ^ m_localizedValueFromFormat;
Platform::String ^ m_localizedValueFromDecimalFormat;

Просмотреть файл

@ -30,6 +30,7 @@
#include <concrt.h>
#include <regex>
#include <iterator>
#include <intsafe.h>
// C++\WinRT Headers
#include "winrt/base.h"
#include "winrt/Windows.Foundation.Diagnostics.h"

Просмотреть файл

@ -4,7 +4,6 @@
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="using:CalculatorApp.Common"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
Loaded="UserControl_Loaded"
mc:Ignorable="d">
<UserControl.Transitions>
<TransitionCollection>

Просмотреть файл

@ -61,8 +61,3 @@ void AboutFlyout::SetDefaultFocus()
{
AboutFlyoutEULA->Focus(::FocusState::Programmatic);
}
void CalculatorApp::AboutFlyout::UserControl_Loaded(Platform::Object ^ sender, Windows::UI::Xaml::RoutedEventArgs ^ e)
{
TraceLogger::GetInstance().LogAboutFlyoutOpened();
}

Просмотреть файл

@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#pragma once
@ -18,6 +18,5 @@ public
private:
void FeedbackButton_Click(_In_ Platform::Object ^ sender, _In_ Windows::UI::Xaml::RoutedEventArgs ^ e);
void SetVersionString();
void UserControl_Loaded(Platform::Object ^ sender, Windows::UI::Xaml::RoutedEventArgs ^ e);
};
} /* namespace CalculatorApp */

Просмотреть файл

@ -134,6 +134,8 @@
<x:Double x:Key="CalcStandardOperatorCaptionSizeLarge">24</x:Double>
<!-- Numpad Standard/Scientific in Fill/Full -->
<x:Double x:Key="CalcStandardOperatorCaptionSize">20</x:Double>
<x:Double x:Key="CalcStandardOperatorCaptionSizeSmall">15</x:Double>
<x:Double x:Key="CalcStandardOperatorCaptionSizeTiny">12</x:Double>
<!-- Standard Operators Standard/Scientific in Fill/Full -->
<x:Double x:Key="CalcOperatorCaptionSize">15</x:Double>
@ -216,11 +218,21 @@
TargetType="Controls:CalculatorButton">
<Setter Property="FontWeight" Value="SemiBold"/>
</Style>
<Style x:Key="NumericButtonStyle10"
BasedOn="{StaticResource NumericButtonStyle}"
TargetType="Controls:CalculatorButton">
<Setter Property="FontSize" Value="10"/>
</Style>
<Style x:Key="NumericButtonStyle12"
BasedOn="{StaticResource NumericButtonStyle}"
TargetType="Controls:CalculatorButton">
<Setter Property="FontSize" Value="12"/>
</Style>
<Style x:Key="NumericButtonStyle16"
BasedOn="{StaticResource NumericButtonStyle}"
TargetType="Controls:CalculatorButton">
<Setter Property="FontSize" Value="16"/>
</Style>
<Style x:Key="NumericButtonStyle18"
BasedOn="{StaticResource NumericButtonStyle}"
TargetType="Controls:CalculatorButton">

Просмотреть файл

@ -60,7 +60,6 @@ namespace CalculatorApp
/// </summary>
App::App()
{
TraceLogger::GetInstance().LogAppLaunchStart();
InitializeComponent();
m_preLaunched = false;
@ -71,6 +70,8 @@ App::App()
// Currently this is bugged so the property is only respected from code-behind.
this->HighContrastAdjustment = ApplicationHighContrastAdjustment::None;
this->Suspending += ref new SuspendingEventHandler(this, &App::OnSuspending);
#if _DEBUG
this->DebugSettings->IsBindingTracingEnabled = true;
this->DebugSettings->BindingFailed += ref new BindingFailedEventHandler([](_In_ Object ^ /*sender*/, _In_ BindingFailedEventArgs ^ e) {
@ -219,21 +220,16 @@ Frame ^ App::CreateFrame()
/// <param name="e">Details about the launch request and process.</param>
void App::OnLaunched(LaunchActivatedEventArgs ^ args)
{
TraceLogger::GetInstance().LogWindowLaunched();
if (args->PrelaunchActivated)
{
// If the app got pre-launch activated, then save that state in a flag
m_preLaunched = true;
TraceLogger::GetInstance().LogAppPrelaunchedBySystem();
}
OnAppLaunch(args, args->Arguments);
}
void App::OnAppLaunch(IActivatedEventArgs ^ args, String ^ argument)
{
auto previousExecutionState = args->PreviousExecutionState;
TraceLogger::GetInstance().LogOnAppLaunch(previousExecutionState.ToString()->Data());
// Uncomment the following lines to display frame-rate and per-frame CPU usage info.
//#if _DEBUG
@ -307,7 +303,6 @@ void App::OnAppLaunch(IActivatedEventArgs ^ args, String ^ argument)
else
{
// For first launch, LaunchStart is logged in constructor, this is for subsequent launches.
TraceLogger::GetInstance().LogAppLaunchStart();
// !Phone check is required because even in continuum mode user interaction mode is Mouse not Touch
if ((UIViewSettings::GetForCurrentView()->UserInteractionMode == UserInteractionMode::Mouse)
@ -319,7 +314,6 @@ void App::OnAppLaunch(IActivatedEventArgs ^ args, String ^ argument)
auto newCoreAppView = CoreApplication::CreateNewView();
newCoreAppView->Dispatcher->RunAsync(
CoreDispatcherPriority::Normal, ref new DispatchedHandler([args, argument, minWindowSize, weak]() {
TraceLogger::GetInstance().LogNewWindowCreationBegin(ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
auto that = weak.Resolve<App>();
if (that != nullptr)
{
@ -372,13 +366,10 @@ void App::OnAppLaunch(IActivatedEventArgs ^ args, String ^ argument)
}
}
}
TraceLogger::GetInstance().LogNewWindowCreationEnd(ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
}));
}
else
{
TraceLogger::GetInstance().LogNewWindowCreationBegin(ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
ActivationViewSwitcher ^ activationViewSwitcher;
auto activateEventArgs = dynamic_cast<IViewSwitcherProvider ^>(args);
if (activateEventArgs != nullptr)
@ -390,12 +381,10 @@ void App::OnAppLaunch(IActivatedEventArgs ^ args, String ^ argument)
{
activationViewSwitcher->ShowAsStandaloneAsync(
ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()), ViewSizePreference::Default);
TraceLogger::GetInstance().LogNewWindowCreationEnd(ApplicationView::GetApplicationViewIdForWindow(CoreWindow::GetForCurrentThread()));
TraceLogger::GetInstance().LogPrelaunchedAppActivatedByUser();
}
else
{
TraceLogger::GetInstance().LogError(L"Null_ActivationViewSwitcher");
TraceLogger::GetInstance().LogError(ViewMode::None, L"App::OnAppLaunch", L"Null_ActivationViewSwitcher");
}
}
// Set the preLaunched flag to false
@ -415,27 +404,30 @@ void App::OnAppLaunch(IActivatedEventArgs ^ args, String ^ argument)
throw std::bad_exception();
}
}
if (!Windows::Foundation::Metadata::ApiInformation::IsTypePresent("Windows.Phone.UI.Input.HardwareButtons"))
if (ApplicationView::GetForCurrentView()->ViewMode != ApplicationViewMode::CompactOverlay)
{
// for tablet mode: since system view activation policy is disabled so do ShowAsStandaloneAsync if activationViewSwitcher exists in
// activationArgs
ActivationViewSwitcher ^ activationViewSwitcher;
auto activateEventArgs = dynamic_cast<IViewSwitcherProvider ^>(args);
if (activateEventArgs != nullptr)
if (!Windows::Foundation::Metadata::ApiInformation::IsTypePresent("Windows.Phone.UI.Input.HardwareButtons"))
{
activationViewSwitcher = activateEventArgs->ViewSwitcher;
}
if (activationViewSwitcher != nullptr)
{
auto viewId = safe_cast<IApplicationViewActivatedEventArgs ^>(args)->CurrentlyShownApplicationViewId;
if (viewId != 0)
// for tablet mode: since system view activation policy is disabled so do ShowAsStandaloneAsync if activationViewSwitcher exists in
// activationArgs
ActivationViewSwitcher ^ activationViewSwitcher;
auto activateEventArgs = dynamic_cast<IViewSwitcherProvider ^>(args);
if (activateEventArgs != nullptr)
{
activationViewSwitcher->ShowAsStandaloneAsync(viewId);
activationViewSwitcher = activateEventArgs->ViewSwitcher;
}
if (activationViewSwitcher != nullptr)
{
auto viewId = safe_cast<IApplicationViewActivatedEventArgs ^>(args)->CurrentlyShownApplicationViewId;
if (viewId != 0)
{
activationViewSwitcher->ShowAsStandaloneAsync(viewId);
}
}
}
// Ensure the current window is active
Window::Current->Activate();
}
// Ensure the current window is active
Window::Current->Activate();
}
}
}
@ -460,13 +452,17 @@ void App::OnActivated(IActivatedEventArgs ^ args)
{
if (args->Kind == ActivationKind::Protocol)
{
TraceLogger::GetInstance().LogWindowActivated();
// We currently don't pass the uri as an argument,
// and handle any protocol launch as a normal app launch.
OnAppLaunch(args, nullptr);
}
}
void CalculatorApp::App::OnSuspending(Object ^ sender, SuspendingEventArgs ^ args)
{
TraceLogger::GetInstance().LogButtonUsage();
}
void App::DismissedEventHandler(SplashScreen ^ sender, Object ^ e)
{
SetupJumpList();
@ -477,3 +473,4 @@ float App::GetAppWindowHeight()
CoreWindow ^ window = CoreWindow::GetForCurrentThread();
return window->Bounds.Height;
}

Просмотреть файл

@ -1,4 +1,4 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
//
@ -42,6 +42,8 @@ namespace CalculatorApp
void OnAppLaunch(Windows::ApplicationModel::Activation::IActivatedEventArgs ^ args, Platform::String ^ argument);
void DismissedEventHandler(Windows::ApplicationModel::Activation::SplashScreen ^ sender, Platform::Object ^ e);
void RegisterDependencyProperties();
void OnSuspending(Platform::Object ^ sender, Windows::ApplicationModel::SuspendingEventArgs ^ args);
class SafeFrameWindowCreation final
{

Двоичные данные
src/Calculator/Assets/CalcMDL2.ttf

Двоичный файл не отображается.

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 185 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 180 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 198 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 193 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 234 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 231 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 1.4 KiB

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 1.4 KiB

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 267 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 262 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 288 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 284 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 309 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 303 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 314 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 311 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 370 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 370 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 446 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 440 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 470 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 476 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 507 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 507 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 507 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 502 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 633 B

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 634 B

Просмотреть файл

@ -8,7 +8,7 @@
<MinimumVisualStudioVersion>15.0</MinimumVisualStudioVersion>
<AppContainerApplication>true</AppContainerApplication>
<ApplicationType>Windows Store</ApplicationType>
<WindowsTargetPlatformVersion Condition="'$(WindowsTargetPlatformVersion)' == ''">10.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformVersion Condition="'$(WindowsTargetPlatformVersion)' == ''">10.0.18362.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion>10.0.18362.0</WindowsTargetPlatformMinVersion>
<!-- We want to manually control the MinVersion/MaxVersionTested in the manifest so turn of the replacement. -->
<AppxOSMinVersionReplaceManifestVersion>false</AppxOSMinVersionReplaceManifestVersion>
@ -219,7 +219,7 @@
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(IsStoreBuild)' == 'True'">
<ClCompile>
<AdditionalOptions>/DSEND_TELEMETRY %(AdditionalOptions)</AdditionalOptions>
<AdditionalOptions>/DSEND_DIAGNOSTICS /DIS_STORE_BUILD %(AdditionalOptions)</AdditionalOptions>
</ClCompile>
</ItemDefinitionGroup>
<PropertyGroup>
@ -243,7 +243,6 @@
<ClInclude Include="Controls\OverflowTextBlock.h" />
<ClInclude Include="Controls\RadixButton.h" />
<ClInclude Include="Controls\SupplementaryItemsControl.h" />
<ClInclude Include="Converters\BitFlipAutomationNameConverter.h" />
<ClInclude Include="Converters\BooleanNegationConverter.h" />
<ClInclude Include="Converters\BooleanToVisibilityConverter.h" />
<ClInclude Include="Converters\ExpressionItemTemplateSelector.h" />
@ -382,7 +381,6 @@
<ClCompile Include="Controls\OverflowTextBlock.cpp" />
<ClCompile Include="Controls\RadixButton.cpp" />
<ClCompile Include="Controls\SupplementaryItemsControl.cpp" />
<ClCompile Include="Converters\BitFlipAutomationNameConverter.cpp" />
<ClCompile Include="Converters\BooleanNegationConverter.cpp" />
<ClCompile Include="Converters\BooleanToVisibilityConverter.cpp" />
<ClCompile Include="Converters\ExpressionItemTemplateSelector.cpp" />
@ -638,99 +636,71 @@
<Image Include="Assets\CalculatorAppList.contrast-white_targetsize-80.png" />
<Image Include="Assets\CalculatorAppList.contrast-white_targetsize-96.png" />
<Image Include="Assets\CalculatorAppList.targetsize-16.png" />
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-20.png" />
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-24.png" />
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-256.png" />
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-30.png" />
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-32.png" />
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-36.png" />
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-40.png" />
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-48.png" />
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-60.png" />
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-64.png" />
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-72.png" />
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-80.png" />
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-unplated_contrast-black.png" />
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-unplated_contrast-white.png" />
<Image Include="Assets\CalculatorAppList.targetsize-96.png" />
<Image Include="Assets\CalculatorAppList.targetsize-96_altform-colorize.png" />
<Image Include="Assets\CalculatorAppList.targetsize-96_altform-fullcolor.png" />
<Image Include="Assets\CalculatorAppList.targetsize-96_altform-lightunplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-96_altform-unplated.png" />
<Image Include="Assets\CalculatorAppList.targetsize-96_altform-unplated_contrast-black.png" />

Просмотреть файл

@ -326,9 +326,6 @@
<ClInclude Include="Controls\OverflowTextBlock.h">
<Filter>Controls</Filter>
</ClInclude>
<ClCompile Include="Converters\BitFlipAutomationNameConverter.cpp">
<Filter>Converters</Filter>
</ClCompile>
<ClInclude Include="Converters\BooleanNegationConverter.h">
<Filter>Converters</Filter>
</ClInclude>
@ -370,9 +367,6 @@
</ClInclude>
<ClInclude Include="WindowFrameService.h" />
<ClInclude Include="Views\DateCalculator.xaml.h" />
<ClInclude Include="Converters\BitFlipAutomationNameConverter.h">
<Filter>Converters</Filter>
</ClInclude>
<ClInclude Include="Controls\CalculationResultAutomationPeer.h">
<Filter>Controls</Filter>
</ClInclude>
@ -1281,90 +1275,6 @@
<Image Include="Assets\CalculatorStoreLogo.contrast-white_scale-100.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-96_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-fullcolor.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-96_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-60_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-64_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-72_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-80_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-30_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-32_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-36_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-40_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-48_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-256_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-16_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-20_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorAppList.targetsize-24_altform-colorize.png">
<Filter>Assets</Filter>
</Image>
<Image Include="Assets\CalculatorSplashScreen.contrast-white_scale-400.png">
<Filter>Assets</Filter>
</Image>

Просмотреть файл

@ -15,18 +15,18 @@ using namespace winrt::Windows::UI::ViewManagement;
namespace CalculatorApp
{
#ifdef SEND_TELEMETRY
#ifdef SEND_DIAGNOSTICS
// c.f. WINEVENT_KEYWORD_RESERVED_63-56 0xFF00000000000000 // Bits 63-56 - channel keywords
// c.f. WINEVENT_KEYWORD_* 0x00FF000000000000 // Bits 55-48 - system-reserved keywords
constexpr int64_t MICROSOFT_KEYWORD_CRITICAL_DATA = 0x0000800000000000; // Bit 47
constexpr int64_t MICROSOFT_KEYWORD_MEASURES = 0x0000400000000000; // Bit 46
constexpr int64_t MICROSOFT_KEYWORD_TELEMETRY = 0x0000200000000000; // Bit 45
constexpr int64_t MICROSOFT_KEYWORD_LEVEL_1 = 0x0000800000000000; // Bit 47
constexpr int64_t MICROSOFT_KEYWORD_LEVEL_2 = 0x0000400000000000; // Bit 46
constexpr int64_t MICROSOFT_KEYWORD_LEVEL_3 = 0x0000200000000000; // Bit 45
constexpr int64_t MICROSOFT_KEYWORD_RESERVED_44 = 0x0000100000000000; // Bit 44 (reserved for future assignment)
#else
// define all Keyword options as 0 when we do not want to upload app telemetry
constexpr int64_t MICROSOFT_KEYWORD_CRITICAL_DATA = 0;
constexpr int64_t MICROSOFT_KEYWORD_MEASURES = 0;
constexpr int64_t MICROSOFT_KEYWORD_TELEMETRY = 0;
// define all Keyword options as 0 when we do not want to upload app diagnostics
constexpr int64_t MICROSOFT_KEYWORD_LEVEL_1 = 0;
constexpr int64_t MICROSOFT_KEYWORD_LEVEL_2 = 0;
constexpr int64_t MICROSOFT_KEYWORD_LEVEL_3 = 0;
constexpr int64_t MICROSOFT_KEYWORD_RESERVED_44 = 0;
#endif
@ -35,7 +35,7 @@ namespace CalculatorApp
AppLifecycleLogger::AppLifecycleLogger()
: m_appLifecycleProvider(
L"Microsoft.Windows.AppLifeCycle",
LoggingChannelOptions(GUID{ 0x4f50731a, 0x89cf, 0x4782, 0xb3, 0xe0, 0xdc, 0xe8, 0xc9, 0x4, 0x76, 0xba }), // Microsoft Telemetry group
LoggingChannelOptions(GUID{ 0x4f50731a, 0x89cf, 0x4782, 0xb3, 0xe0, 0xdc, 0xe8, 0xc9, 0x4, 0x76, 0xba }),
GUID{ 0xef00584a, 0x2655, 0x462c, 0xbc, 0x24, 0xe7, 0xde, 0x63, 0xe, 0x7f, 0xbf }) // Unique provider ID {EF00584A-2655-462C-BC24-E7DE630E7FBF}
{
}
@ -59,7 +59,7 @@ namespace CalculatorApp
void AppLifecycleLogger::LogAppLifecycleEvent(hstring const& eventName, LoggingFields const& fields) const
{
m_appLifecycleProvider.LogEvent(
eventName, fields, LoggingLevel::Information, LoggingOptions(MICROSOFT_KEYWORD_TELEMETRY | WINEVENT_KEYWORD_RESPONSE_TIME));
eventName, fields, LoggingLevel::Information, LoggingOptions(MICROSOFT_KEYWORD_LEVEL_3 | WINEVENT_KEYWORD_RESPONSE_TIME));
}
#pragma endregion

Просмотреть файл

@ -31,8 +31,8 @@ namespace CalculatorApp
// Any new Log method should
// a) Decide the level of logging. This will help us in limiting recording of events only up to a certain level. See this link for guidance
// https://msdn.microsoft.com/en-us/library/windows/desktop/aa363742(v=vs.85).aspx We're using Verbose level for events that are called frequently and
// needed only for debugging or capturing perf for specific scenarios b) Should decide whether or not to log to telemetry and pass
// TraceLoggingKeyword(MICROSOFT_KEYWORD_TELEMETRY) accordingly c) Should accept a variable number of additional data arguments if needed
// needed only for debugging or capturing perf for specific scenarios b) Should decide whether or not to log to diagnostics and pass
// TraceLoggingKeyword(MICROSOFT_KEYWORD_LEVEL_3) accordingly c) Should accept a variable number of additional data arguments if needed
void LogAppLifecycleEvent(winrt::hstring const& eventName, winrt::Windows::Foundation::Diagnostics::LoggingFields const& fields) const;
void PopulateAppInfo(winrt::Windows::Foundation::Diagnostics::LoggingFields& fields) const;

Просмотреть файл

@ -27,6 +27,9 @@ using namespace Windows::UI::Xaml::Navigation;
DEPENDENCY_PROPERTY_INITIALIZATION(OverflowTextBlock, IsActive);
DEPENDENCY_PROPERTY_INITIALIZATION(OverflowTextBlock, TextStyle);
DEPENDENCY_PROPERTY_INITIALIZATION(OverflowTextBlock, TokensUpdated);
DEPENDENCY_PROPERTY_INITIALIZATION(OverflowTextBlock, ColumnWidth);
DEPENDENCY_PROPERTY_INITIALIZATION(OverflowTextBlock, ColumnHeight);
DEPENDENCY_PROPERTY_INITIALIZATION(OverflowTextBlock, ScrollButtonFontSize);
void OverflowTextBlock::OnApplyTemplate()
{
@ -64,6 +67,12 @@ void OverflowTextBlock::OnApplyTemplate()
m_itemsControl = safe_cast<ItemsControl ^>(uiElement);
}
uiElement = GetTemplateChild("EditableToken");
if (uiElement != nullptr)
{
m_editableToken = safe_cast<TextBlock ^>(uiElement);
}
UpdateAllState();
}
@ -144,13 +153,25 @@ void OverflowTextBlock::OnScrollClick(_In_ Object ^ sender, _In_ RoutedEventArgs
void OverflowTextBlock::UpdateScrollButtons()
{
if (m_itemsControl == nullptr || m_expressionContainer == nullptr)
if (m_expressionContainer == nullptr)
{
return;
}
double editableTokenWidth = 0;
if (m_editableToken != nullptr && m_editableToken->Visibility == ::Visibility::Visible)
{
editableTokenWidth = m_editableToken->ActualWidth;
}
double itemsControlWidth = 0;
if (m_itemsControl != nullptr && m_itemsControl->Visibility == ::Visibility::Visible)
{
itemsControlWidth = m_itemsControl->ActualWidth;
}
// When the width is smaller than the container, don't show any
if (m_itemsControl->ActualWidth <= m_expressionContainer->ActualWidth)
if (itemsControlWidth + editableTokenWidth <= m_expressionContainer->ActualWidth)
{
ShowHideScrollButtons(::Visibility::Collapsed, ::Visibility::Collapsed);
}
@ -161,7 +182,7 @@ void OverflowTextBlock::UpdateScrollButtons()
{
ShowHideScrollButtons(::Visibility::Visible, ::Visibility::Visible);
}
// Width is larger than the container and left most part of the number is shown. Should be able to scroll left.
// Width is larger than the container and left most part of the number is shown. Should be able to scroll right.
else if (m_expressionContainer->HorizontalOffset == 0)
{
ShowHideScrollButtons(::Visibility::Collapsed, ::Visibility::Visible);

Просмотреть файл

@ -18,10 +18,14 @@ namespace CalculatorApp
}
DEPENDENCY_PROPERTY_OWNER(OverflowTextBlock);
DEPENDENCY_PROPERTY_WITH_CALLBACK(bool, TokensUpdated);
DEPENDENCY_PROPERTY(bool, IsActive);
DEPENDENCY_PROPERTY(Windows::UI::Xaml::Style ^, TextStyle);
DEPENDENCY_PROPERTY(double, ColumnWidth);
DEPENDENCY_PROPERTY(double, ColumnHeight);
DEPENDENCY_PROPERTY(double, ScrollButtonFontSize);
void OnTokensUpdatedPropertyChanged(bool oldValue, bool newValue);
void UpdateScrollButtons();
void UnregisterEventHandlers();
@ -34,7 +38,6 @@ namespace CalculatorApp
void OnPointerEntered(_In_ Platform::Object ^ sender, _In_ Windows::UI::Xaml::Input::PointerRoutedEventArgs ^ e);
void OnPointerExited(_In_ Platform::Object ^ sender, _In_ Windows::UI::Xaml::Input::PointerRoutedEventArgs ^ e);
void ShowHideScrollButtons(Windows::UI::Xaml::Visibility vLeft, Windows::UI::Xaml::Visibility vRight);
void OnTokensUpdatedPropertyChanged(bool oldValue, bool newValue);
void OnViewChanged(_In_opt_ Platform::Object ^ sender, _In_opt_ Windows::UI::Xaml::Controls::ScrollViewerViewChangedEventArgs ^ args);
void UpdateVisualState();
@ -47,6 +50,7 @@ namespace CalculatorApp
bool m_scrollingLeft;
bool m_scrollingRight;
bool m_isAccessibilityViewControl;
Windows::UI::Xaml::Controls::TextBlock ^ m_editableToken;
Windows::UI::Xaml::Controls::ItemsControl ^ m_itemsControl;
Windows::UI::Xaml::Controls::ScrollViewer ^ m_expressionContainer;
Windows::UI::Xaml::Controls::Button ^ m_scrollLeft;

Просмотреть файл

@ -1,80 +0,0 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#include "pch.h"
#include "CalcViewModel/Common/AppResourceProvider.h"
#include "CalcViewModel/Common/LocalizationSettings.h"
#include "BitFlipAutomationNameConverter.h"
using namespace CalculatorApp::Common;
using namespace CalculatorApp::Converters;
using namespace Platform;
using namespace std;
using namespace Windows::ApplicationModel::Resources;
using namespace Windows::Foundation;
using namespace Windows::UI::Xaml::Interop;
// returns automationName in form "Nth bit Value zero/one" depending if bit is set/unset at corresponding index of binary display
Object ^ BitFlipAutomationNameConverter::Convert(_In_ Object ^ value, TypeName targetType, _In_ Object ^ parameter, _In_ String ^ language)
{
auto resourceLoader = AppResourceProvider::GetInstance();
// initialising the updated display with 64 bits of zeros
wstring updatedBinaryDisplay(64, L'0');
const auto& localizationSettings = LocalizationSettings::GetInstance();
wchar_t ch0 = localizationSettings.GetDigitSymbolFromEnUsDigit('0');
wchar_t ch1 = localizationSettings.GetDigitSymbolFromEnUsDigit('1');
String ^ indexName = resourceLoader.GetResourceString(static_cast<String ^>(parameter));
String ^ bitName = resourceLoader.GetResourceString(L"BitAutomationName");
String ^ valueName = resourceLoader.GetResourceString(L"ValueAutomationName");
String ^ zero = resourceLoader.GetResourceString(L"BinaryZeroValueAutomationName");
String ^ one = resourceLoader.GetResourceString(L"BinaryOneValueAutomationName");
if ((value != nullptr) && (parameter != nullptr))
{
wstring binaryDisplay = (static_cast<String ^>(value))->Data();
wstring indexString = (static_cast<String ^>(parameter))->Data();
wstringstream converter;
converter << indexString;
unsigned int index;
converter >> index;
unsigned int binaryLength = 0;
// remove all the characters except 0 and 1 from the array.
for (wchar_t bit : binaryDisplay)
{
if ((bit == ch1) || (bit == ch0))
{
updatedBinaryDisplay[binaryLength++] = bit;
}
if (binaryLength == 63)
{
break;
}
}
// return if binaryDisplay is empty
if (binaryLength == 0)
{
return (indexName + bitName + valueName + zero);
}
// if index is more than the length of binary display return automation name with zero
if (index >= binaryLength)
{
return (indexName + bitName + valueName + zero);
}
// if bit is set return automation name with one else return zero
if (updatedBinaryDisplay[binaryLength - index - 1] == ch1)
{
return (indexName + bitName + valueName + one);
}
}
return (indexName + bitName + valueName + zero);
}
Object ^ BitFlipAutomationNameConverter::ConvertBack(_In_ Object ^ value, TypeName targetType, _In_ Object ^ parameter, _In_ String ^ language)
{
return value;
}

Просмотреть файл

@ -1,30 +0,0 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#pragma once
namespace CalculatorApp
{
namespace Converters
{
/// <summary>
/// Value converter that translates binary value to automation name for a bit.
/// </summary>
[Windows::Foundation::Metadata::WebHostHidden] public ref class BitFlipAutomationNameConverter sealed : Windows::UI::Xaml::Data::IValueConverter
{
public:
virtual Platform::Object
^ Convert(
_In_ Platform::Object ^ value,
Windows::UI::Xaml::Interop::TypeName targetType,
_In_ Platform::Object ^ parameter,
_In_ Platform::String ^ language);
virtual Platform::Object
^ ConvertBack(
_In_ Platform::Object ^ value,
Windows::UI::Xaml::Interop::TypeName targetType,
_In_ Platform::Object ^ parameter,
_In_ Platform::String ^ language);
};
}
}

Просмотреть файл

@ -433,6 +433,14 @@
<value>Sluit geheue-uitvlieg</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Hou bo</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Terug na volle aansig</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Geheue</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Vertoon is %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Uitdrukking is %1, huidige toevoer is %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Beeld is %1 punt</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Aftrekkieslys vir kategorieë</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Hou bo</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Terug na volle aansig</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Hou bo</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Terug na volle aansig</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Skakel om vanaf %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Verskil</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<value>Van</value>
<comment>From Date label for Date Picker</comment>
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>Vanaf</value>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Maande</value>
@ -2444,9 +2472,9 @@
<value>Aftrek</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Aan</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Jaar</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>Vanaf</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Rolberekening-resultaat is links</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Rolberekening-resultaat is regs</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Berekening het misluk</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>ትውስታ ፍላይአውት ዝጋ</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>ከላይ ያቆዩ</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>ወደ ሙሉ ዕይታ ይመለሱ</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>ማኅደረ ትውስታ</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>ማሳያ %1 ነው</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>የሒሳብ ሓረግ %1፣ አሁን ያለው ግቤት %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>ማሳያ %1 ነጥብ ነው</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>የመደቦች ቁልቁል ወራጅ</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>ከላይ ያቆዩ</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>ወደ ሙሉ ዕይታ ይመለሱ</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>ከላይ ያቆዩ</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>ወደ ሙሉ ዕይታ ይመለሱ</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>ከ%1 %2 ይቀይሩ</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>ልዩነት</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>ከ</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>ወሮች</value>
@ -2444,9 +2472,9 @@
<value>ቀንስ</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<value></value>
<comment>To Date label for Date Picker</comment>
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>እስከ</value>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>ዓመታት</value>
@ -2915,6 +2943,10 @@
<value>ፒዮንግ</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>ከ</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>የስሌት ውጤቱን ወደ ግራ ይሸብልሉ</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>የስሌት ውጤቱን ወደ ቀኝ ይሸብልሉ</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>ማስላት አልተሳካም</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>إغلاق قائمة الذاكرة المنبثقة</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>الاستمرار في المتابعة</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>العودة إلى طريقة العرض الكاملة</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>الذاكرة</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>الناتج %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>التعبير هو %1، الإدخال الحالي هو %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>العرض هو %1 نقطة</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>القائمة المنسدلة للفئات</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>الاستمرار في المتابعة</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>العودة إلى طريقة العرض الكاملة</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>الاستمرار في المتابعة</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>العودة إلى طريقة العرض الكاملة</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>تحويل من %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2433,9 +2461,9 @@
<value>الاختلاف</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>من</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>شهور</value>
@ -2445,9 +2473,9 @@
<value>اجتزاء</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>إلى</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>سنوات</value>
@ -2916,6 +2944,10 @@
<value>بيونغ</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>من</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>تمرير نتيجة الحساب إلى اليسار</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2924,4 +2956,8 @@
<value>تمرير نتيجة الحساب إلى اليمين</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>فشل الحساب</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Yaddaş menyusunu bağla</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Digər pəncərələrin üzərində saxla</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Tam görünüşə qayıt</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Yaddaş</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Displey: %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>İfadə %1, Cari daxiletmə %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Displey %1 xaldır</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Kateqoriyalar üzrə aşağıılan menyu</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Digər pəncərələrin üzərində saxla</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Tam görünüşə qayıt</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Digər pəncərələrin üzərində saxla</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Tam görünüşə qayıt</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>%1 %2-dan çevir</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Fərq</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<value>Nə vaxta kimi</value>
<comment>From Date label for Date Picker</comment>
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>Bu vaxtdan</value>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Aylar</value>
@ -2444,9 +2472,9 @@
<value>Çıxar</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<value>Nə vaxtdan</value>
<comment>To Date label for Date Picker</comment>
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Bu vaxta kimi</value>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>İl</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>Bu vaxtdan</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Hesablama nəticəsini sola sürüşdürün</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Hesablama nəticəsini sağa sürüşdürün</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Hesablama uğursuz oldu</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Закрыць усплывальнае меню памяці</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Трымаць зверху</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Вярнуцца да поўнаэкраннага прагляду</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Памяць</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Адлюстраванне – %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Выраз: %1, бягучы вынік: %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Для паказу патрэбны %1 бал</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Выпадное меню катэгорый</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Трымаць зверху</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Вярнуцца да поўнаэкраннага прагляду</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Трымаць зверху</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Вярнуцца да поўнаэкраннага прагляду</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Пераўтварыць з %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Розніца</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>Пачатак</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Месяцы</value>
@ -2444,9 +2472,9 @@
<value>Адняць</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Канец</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Гады</value>
@ -2915,6 +2943,10 @@
<value>Пхён</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>Пачатак</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Прагартаць вынікі вылічэння ўлева</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Прагартаць вынікі вылічэння ўправа</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Памылка падлікаў</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Затвори допълнителното меню за памет</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Задържане отгоре</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Обратно към пълния изглед</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Памет</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Изгледът е %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Изразът е %1, текущите входни данни са %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Показва се в запетая до %1</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Падащо меню с категории</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Задържане отгоре</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Обратно към пълния изглед</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Задържане отгоре</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Обратно към пълния изглед</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Конвертиране от %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Разлика</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>От</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Месеци</value>
@ -2444,9 +2472,9 @@
<value>Извади</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>До</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Години</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>От</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Превъртане наляво на резултата от изчислението</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Превъртане надясно на резултата от изчислението</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Изчислението е неуспешно</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>মেমোরি ফ্লাইআউট বন্ধ করুন</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>উপরে রাখা</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>সম্পূর্ণ দৃশ্যে ফিরে যান</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>স্মৃতি</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>প্রদর্শন হল %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>অভিব্যক্তি %1, বর্তমান ইনপুট %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>প্রদর্শন হল %1 পয়েন্ট</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>শ্রেণি তালিকা নিম্ন-প্রসারিত</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>উপরে রাখা</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>সম্পূর্ণ দৃশ্যে ফিরে যান</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>উপরে রাখা</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>সম্পূর্ণ দৃশ্যে ফিরে যান</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>%1 %2 -এর থেকে পরিবর্তন করুন</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>পার্থক্য</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>থেকে</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>মাস</value>
@ -2444,9 +2472,9 @@
<value>বিয়োগ করুন</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>প্রতি</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>বছর</value>
@ -2915,6 +2943,10 @@
<value>পিয়ং</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>থেকে</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>স্ক্রোল গণনা ফলাফল বাম</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>স্ক্রোল গণনা ফলাফল ডান</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>গণনা ব্যর্থ হয়েছে</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Tanca el desplegable de memòria</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Mantén visible</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Torna a la visualització completa</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Memòria</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>La visualització és %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>L'expressió és %1, l'entrada actual és %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>La pantalla mostra %1 coma.</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Desplegable de categories</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Mantén visible</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Torna a la visualització completa</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Mantén visible</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Torna a la visualització completa</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Converteix de %1 %2.</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Diferència</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>De</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Mesos</value>
@ -2444,9 +2472,9 @@
<value>Resta</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Per a</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Anys</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>De</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Desplaça el resultat del càlcul a l'esquerra</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Desplaça el resultat del càlcul a la dreta</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>No s'ha pogut calcular</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Zavřít informační rámeček paměti</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Vždy navrchu</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Zpět do úplného zobrazení</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Paměť</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Zobrazuje se %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Výraz: %1. Aktuální vstup: %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Zobrazuje se %1 bod</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Rozevírací seznam Kategorie</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Vždy navrchu</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Zpět do úplného zobrazení</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Vždy navrchu</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Zpět do úplného zobrazení</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>převést z %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2218,7 +2246,7 @@
<comment>A sheet of 8.5 x 11 inch paper, used as a comparison measurement unit for area. (Please choose the most appropriate plural form to fit any number between 0 and 999,999,999,999,999)</comment>
</data>
<data name="UnitAbbreviation_Paper" xml:space="preserve">
<value>listy papíru</value>
<value>listů papíru</value>
<comment>A sheet of 8.5 x 11 inch paper, used as a comparison measurement unit for area. (Please choose the most appropriate plural form to fit any number between 0 and 999,999,999,999,999)</comment>
</data>
<data name="UnitName_Castle" xml:space="preserve">
@ -2432,9 +2460,9 @@
<value>Rozdíl</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>Od</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Měsíce</value>
@ -2444,9 +2472,9 @@
<value>Odečíst</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Do</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Roky</value>
@ -2915,6 +2943,10 @@
<value>Pyong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>Od</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Posunout výsledek výpočtu doleva</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Posunout výsledek výpočtu doprava</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Neúspěšný výpočet</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Luk pop op-vindue med hukommelse</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Bevar øverst</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Tilbage til fuld visning</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Hukommelse</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Skærm er %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Udtrykket er %1. Det aktuelle input er %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Resultatet er %1 komma</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Kategorier rulleliste</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Bevar øverst</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Tilbage til fuld visning</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Bevar øverst</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Tilbage til fuld visning</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Konverteres fra %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Forskel</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>Fra</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Måneder</value>
@ -2444,9 +2472,9 @@
<value>Træk fra</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Til</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>År</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>Fra</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Rul til venstre for beregningsresultat</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Rul til højre for beregningsresultat</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Beregning mislykkedes</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Speichererweiterung schließen</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Immer im Vordergrund</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Zurück zum Vollbildmodus</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Speicher</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Die Anzeige lautet %1.</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Ausdruck: %1, aktuelle Eingabe: %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Die Anzeige lautet %1 Komma</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Kategorie-Dropdownfeld</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Immer im Vordergrund</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Zurück zum Vollbildmodus</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Immer im Vordergrund</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Zurück zum Vollbildmodus</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Aus %1 %2 umwandeln</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Differenz</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>Von</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Monate</value>
@ -2444,9 +2472,9 @@
<value>Subtrahieren</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Bis</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Jahre</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>Von</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Berechnungsergebnis nach links scrollen</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Berechnungsergebnis nach rechts scrollen</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Fehler bei der Berechnung</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Κλείσιμο αναδυόμενου στοιχείου μνήμης</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Διατήρηση στην κορυφή</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Επιστροφή στην πλήρη προβολή</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Μνήμη</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Η οθόνη δείχνει %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Η παράσταση είναι %1, η τρέχουσα είσοδος είναι %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Η προβολή δείχνει %1 στιγμή</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Αναπτυσσόμενη λίστα κατηγοριών</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Διατήρηση στην κορυφή</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Επιστροφή στην πλήρη προβολή</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Διατήρηση στην κορυφή</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Επιστροφή στην πλήρη προβολή</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Μετατροπή από %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Διαφορά</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>Από</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Μήνες</value>
@ -2444,9 +2472,9 @@
<value>Αφαίρεση</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<value>Έως</value>
<comment>To Date label for Date Picker</comment>
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>Προς</value>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Έτη</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>Από</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Κύλιση αποτελέσματος υπολογισμού προς τα αριστερά</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Κύλιση αποτελέσματος υπολογισμού προς τα δεξιά</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Ο υπολογισμός απέτυχε</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -433,6 +433,14 @@
<value>Close memory flyout</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Keep on top</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Back to full view</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Memory</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -545,6 +553,10 @@
<value>Display is %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Expression is %1, Current input is %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Display is %1 point</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1057,6 +1069,22 @@
<value>Categories DropDown</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Keep on top</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Back to full view</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Keep on top</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Back to full view</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Convert from %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>
@ -2432,9 +2460,9 @@
<value>Difference</value>
<comment>Difference result label</comment>
</data>
<data name="Date_FromLabel.Text" xml:space="preserve">
<data name="DateDiff_FromHeader.Header" xml:space="preserve">
<value>From</value>
<comment>From Date label for Date Picker</comment>
<comment>From Date Header for Difference Date Picker</comment>
</data>
<data name="MonthsLabel.Text" xml:space="preserve">
<value>Months</value>
@ -2444,9 +2472,9 @@
<value>Subtract</value>
<comment>Subtract toggle button text</comment>
</data>
<data name="Date_ToLabel.Text" xml:space="preserve">
<data name="DateDiff_ToHeader.Header" xml:space="preserve">
<value>To</value>
<comment>To Date label for Date Picker</comment>
<comment>To Date Header for Difference Date Picker</comment>
</data>
<data name="YearsLabel.Text" xml:space="preserve">
<value>Years</value>
@ -2915,6 +2943,10 @@
<value>Pyeong</value>
<comment>A measurement unit for area.</comment>
</data>
<data name="AddSubtract_Date_FromHeader.Header" xml:space="preserve">
<value>From</value>
<comment>From Date Header for AddSubtract Date Picker</comment>
</data>
<data name="CalculationResultScrollLeft.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Scroll Calculation Result Left</value>
<comment>Automation label for the "Scroll Left" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
@ -2923,4 +2955,8 @@
<value>Scroll Calculation Result Right</value>
<comment>Automation label for the "Scroll Right" button that appears when a calculation result is too large to fit in calculation result text box.</comment>
</data>
<data name="CalculationFailed" xml:space="preserve">
<value>Calculation failed</value>
<comment>Text displayed when the application is not able to do a calculation</comment>
</data>
</root>

Просмотреть файл

@ -118,7 +118,7 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="AppName" xml:space="preserve">
<value>Graphing Calculator</value>
<value>Calculator</value>
<comment>{@Appx_ShortDisplayName@}{StringCategory="Feature Title"} This is the title of the official application when published through Windows Store.</comment>
</data>
<data name="DevAppName" xml:space="preserve">
@ -545,276 +545,268 @@
<value>Insert</value>
<comment>{Locked}This is the alternate shortcut for paste, SHIFT+Insert</comment>
</data>
<data name="BitAutomationName" xml:space="preserve">
<value>Bit </value>
<comment>Sub-string used in automation name for each bit in bit flip</comment>
<data name="BitFlipItemAutomationName" xml:space="preserve">
<value>%1, value %2</value>
<comment>{Locked="%1","%2"}. String used in automation name for each bit in bit flip. %1 will be replaced by the position of the bit (1st bit, 3rd bit), %2 by a binary value (1 or 0)</comment>
</data>
<data name="ValueAutomationName" xml:space="preserve">
<value>Value </value>
<comment>Sub-string used in automation name for each bit in bit flip</comment>
<data name="BitPosition" xml:space="preserve">
<value>%1 bit</value>
<comment>{Locked="%1"}. Sub-string used to indicate the position of a bit (e.g. 1st bit, 2nd bit...)</comment>
</data>
<data name="BinaryZeroValueAutomationName" xml:space="preserve">
<value>Zero</value>
<comment>Sub-string used in automation name for each bit in bit flip</comment>
</data>
<data name="BinaryOneValueAutomationName" xml:space="preserve">
<value>One</value>
<comment>Sub-string used in automation name for each bit in bit flip</comment>
</data>
<data name="63" xml:space="preserve">
<value>63rd </value>
<data name="63" xml:space="preserve">
<value>63rd</value>
<comment>Sub-string used in automation name for 63 bit in bit flip</comment>
</data>
<data name="62" xml:space="preserve">
<value>62nd </value>
<value>62nd</value>
<comment>Sub-string used in automation name for 62 bit in bit flip</comment>
</data>
<data name="61" xml:space="preserve">
<value>61st </value>
<value>61st</value>
<comment>Sub-string used in automation name for 61 bit in bit flip</comment>
</data>
<data name="60" xml:space="preserve">
<value>60th </value>
<value>60th</value>
<comment>Sub-string used in automation name for 60 bit in bit flip</comment>
</data>
<data name="59" xml:space="preserve">
<value>59th </value>
<value>59th</value>
<comment>Sub-string used in automation name for 59 bit in bit flip</comment>
</data>
<data name="58" xml:space="preserve">
<value>58th </value>
<value>58th</value>
<comment>Sub-string used in automation name for 58 bit in bit flip</comment>
</data>
<data name="57" xml:space="preserve">
<value>57th </value>
<value>57th</value>
<comment>Sub-string used in automation name for 57 bit in bit flip</comment>
</data>
<data name="56" xml:space="preserve">
<value>56th </value>
<value>56th</value>
<comment>Sub-string used in automation name for 56 bit in bit flip</comment>
</data>
<data name="55" xml:space="preserve">
<value>55th </value>
<value>55th</value>
<comment>Sub-string used in automation name for 55 bit in bit flip</comment>
</data>
<data name="54" xml:space="preserve">
<value>54th </value>
<value>54th</value>
<comment>Sub-string used in automation name for 54 bit in bit flip</comment>
</data>
<data name="53" xml:space="preserve">
<value>53rd </value>
<value>53rd</value>
<comment>Sub-string used in automation name for 53 bit in bit flip</comment>
</data>
<data name="52" xml:space="preserve">
<value>52nd </value>
<value>52nd</value>
<comment>Sub-string used in automation name for 52 bit in bit flip</comment>
</data>
<data name="51" xml:space="preserve">
<value>51st </value>
<value>51st</value>
<comment>Sub-string used in automation name for 51 bit in bit flip</comment>
</data>
<data name="50" xml:space="preserve">
<value>50th </value>
<value>50th</value>
<comment>Sub-string used in automation name for 50 bit in bit flip</comment>
</data>
<data name="49" xml:space="preserve">
<value>49th </value>
<value>49th</value>
<comment>Sub-string used in automation name for 49 bit in bit flip</comment>
</data>
<data name="48" xml:space="preserve">
<value>48th </value>
<value>48th</value>
<comment>Sub-string used in automation name for 48 bit in bit flip</comment>
</data>
<data name="47" xml:space="preserve">
<value>47th </value>
<value>47th</value>
<comment>Sub-string used in automation name for 47 bit in bit flip</comment>
</data>
<data name="46" xml:space="preserve">
<value>46th </value>
<value>46th</value>
<comment>Sub-string used in automation name for 46 bit in bit flip</comment>
</data>
<data name="45" xml:space="preserve">
<value>45th </value>
<value>45th</value>
<comment>Sub-string used in automation name for 45 bit in bit flip</comment>
</data>
<data name="44" xml:space="preserve">
<value>44th </value>
<value>44th</value>
<comment>Sub-string used in automation name for 44 bit in bit flip</comment>
</data>
<data name="43" xml:space="preserve">
<value>43rd </value>
<value>43rd</value>
<comment>Sub-string used in automation name for 43 bit in bit flip</comment>
</data>
<data name="42" xml:space="preserve">
<value>42nd </value>
<value>42nd</value>
<comment>Sub-string used in automation name for 42 bit in bit flip</comment>
</data>
<data name="41" xml:space="preserve">
<value>41st </value>
<value>41st</value>
<comment>Sub-string used in automation name for 41 bit in bit flip</comment>
</data>
<data name="40" xml:space="preserve">
<value>40th </value>
<value>40th</value>
<comment>Sub-string used in automation name for 40 bit in bit flip</comment>
</data>
<data name="39" xml:space="preserve">
<value>39th </value>
<value>39th</value>
<comment>Sub-string used in automation name for 39 bit in bit flip</comment>
</data>
<data name="38" xml:space="preserve">
<value>38th </value>
<value>38th</value>
<comment>Sub-string used in automation name for 38 bit in bit flip</comment>
</data>
<data name="37" xml:space="preserve">
<value>37th </value>
<value>37th</value>
<comment>Sub-string used in automation name for 37 bit in bit flip</comment>
</data>
<data name="36" xml:space="preserve">
<value>36th </value>
<value>36th</value>
<comment>Sub-string used in automation name for 36 bit in bit flip</comment>
</data>
<data name="35" xml:space="preserve">
<value>35th </value>
<value>35th</value>
<comment>Sub-string used in automation name for 35 bit in bit flip</comment>
</data>
<data name="34" xml:space="preserve">
<value>34th </value>
<value>34th</value>
<comment>Sub-string used in automation name for 34 bit in bit flip</comment>
</data>
<data name="33" xml:space="preserve">
<value>33rd </value>
<value>33rd</value>
<comment>Sub-string used in automation name for 33 bit in bit flip</comment>
</data>
<data name="32" xml:space="preserve">
<value>32nd </value>
<value>32nd</value>
<comment>Sub-string used in automation name for 32 bit in bit flip</comment>
</data>
<data name="31" xml:space="preserve">
<value>31st </value>
<value>31st</value>
<comment>Sub-string used in automation name for 31 bit in bit flip</comment>
</data>
<data name="30" xml:space="preserve">
<value>30th </value>
<value>30th</value>
<comment>Sub-string used in automation name for 30 bit in bit flip</comment>
</data>
<data name="29" xml:space="preserve">
<value>29th </value>
<value>29th</value>
<comment>Sub-string used in automation name for 29 bit in bit flip</comment>
</data>
<data name="28" xml:space="preserve">
<value>28th </value>
<value>28th</value>
<comment>Sub-string used in automation name for 28 bit in bit flip</comment>
</data>
<data name="27" xml:space="preserve">
<value>27th </value>
<value>27th</value>
<comment>Sub-string used in automation name for 27 bit in bit flip</comment>
</data>
<data name="26" xml:space="preserve">
<value>26th </value>
<value>26th</value>
<comment>Sub-string used in automation name for 26 bit in bit flip</comment>
</data>
<data name="25" xml:space="preserve">
<value>25th </value>
<value>25th</value>
<comment>Sub-string used in automation name for 25 bit in bit flip</comment>
</data>
<data name="24" xml:space="preserve">
<value>24th </value>
<value>24th</value>
<comment>Sub-string used in automation name for 24 bit in bit flip</comment>
</data>
<data name="23" xml:space="preserve">
<value>23rd </value>
<value>23rd</value>
<comment>Sub-string used in automation name for 23 bit in bit flip</comment>
</data>
<data name="22" xml:space="preserve">
<value>22nd </value>
<value>22nd</value>
<comment>Sub-string used in automation name for 22 bit in bit flip</comment>
</data>
<data name="21" xml:space="preserve">
<value>21st </value>
<value>21st</value>
<comment>Sub-string used in automation name for 21 bit in bit flip</comment>
</data>
<data name="20" xml:space="preserve">
<value>20th </value>
<value>20th</value>
<comment>Sub-string used in automation name for 20 bit in bit flip</comment>
</data>
<data name="19" xml:space="preserve">
<value>19th </value>
<value>19th</value>
<comment>Sub-string used in automation name for 19 bit in bit flip</comment>
</data>
<data name="18" xml:space="preserve">
<value>18th </value>
<value>18th</value>
<comment>Sub-string used in automation name for 18 bit in bit flip</comment>
</data>
<data name="17" xml:space="preserve">
<value>17th </value>
<value>17th</value>
<comment>Sub-string used in automation name for 17 bit in bit flip</comment>
</data>
<data name="16" xml:space="preserve">
<value>16th </value>
<value>16th</value>
<comment>Sub-string used in automation name for 16 bit in bit flip</comment>
</data>
<data name="15" xml:space="preserve">
<value>15th </value>
<value>15th</value>
<comment>Sub-string used in automation name for 15 bit in bit flip</comment>
</data>
<data name="14" xml:space="preserve">
<value>14th </value>
<value>14th</value>
<comment>Sub-string used in automation name for 14 bit in bit flip</comment>
</data>
<data name="13" xml:space="preserve">
<value>13th </value>
<value>13th</value>
<comment>Sub-string used in automation name for 13 bit in bit flip</comment>
</data>
<data name="12" xml:space="preserve">
<value>12th </value>
<value>12th</value>
<comment>Sub-string used in automation name for 12 bit in bit flip</comment>
</data>
<data name="11" xml:space="preserve">
<value>11th </value>
<value>11th</value>
<comment>Sub-string used in automation name for 11 bit in bit flip</comment>
</data>
<data name="10" xml:space="preserve">
<value>10th </value>
<value>10th</value>
<comment>Sub-string used in automation name for 10 bit in bit flip</comment>
</data>
<data name="9" xml:space="preserve">
<value>9th </value>
<value>9th</value>
<comment>Sub-string used in automation name for 9 bit in bit flip</comment>
</data>
<data name="8" xml:space="preserve">
<value>8th </value>
<value>8th</value>
<comment>Sub-string used in automation name for 8 bit in bit flip</comment>
</data>
<data name="7" xml:space="preserve">
<value>7th </value>
<value>7th</value>
<comment>Sub-string used in automation name for 7 bit in bit flip</comment>
</data>
<data name="6" xml:space="preserve">
<value>6th </value>
<value>6th</value>
<comment>Sub-string used in automation name for 6 bit in bit flip</comment>
</data>
<data name="5" xml:space="preserve">
<value>5th </value>
<value>5th</value>
<comment>Sub-string used in automation name for 5 bit in bit flip</comment>
</data>
<data name="4" xml:space="preserve">
<value>4th </value>
<value>4th</value>
<comment>Sub-string used in automation name for 4 bit in bit flip</comment>
</data>
<data name="3" xml:space="preserve">
<value>3rd </value>
<value>3rd</value>
<comment>Sub-string used in automation name for 3 bit in bit flip</comment>
</data>
<data name="2" xml:space="preserve">
<value>2nd </value>
<value>2nd</value>
<comment>Sub-string used in automation name for 2 bit in bit flip</comment>
</data>
<data name="1" xml:space="preserve">
<value>1st </value>
<value>1st</value>
<comment>Sub-string used in automation name for 1 bit in bit flip</comment>
</data>
<data name="0" xml:space="preserve">
<value>0th </value>
<value>0th</value>
<comment>Sub-string used in automation name for 0 bit in bit flip</comment>
</data>
<data name="MemoryButton_Open" xml:space="preserve">
@ -825,6 +817,14 @@
<value>Close memory flyout</value>
<comment>This is the automation name and label for the memory button when the memory flyout is open.</comment>
</data>
<data name="AlwaysOnTop_Enter" xml:space="preserve">
<value>Keep on top</value>
<comment>This is the tool tip automation name for the always-on-top button when out of always-on-top mode.</comment>
</data>
<data name="AlwaysOnTop_Exit" xml:space="preserve">
<value>Back to full view</value>
<comment>This is the tool tip automation name for the always-on-top button when in always-on-top mode.</comment>
</data>
<data name="MemoryButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Memory</value>
<comment>This is the tool tip automation name for the memory button.</comment>
@ -957,6 +957,10 @@
<value>Display is %1</value>
<comment>{Locked="%1"}. Screen reader prompt for the Calculator results text block. %1 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorAlwaysOnTopResults" xml:space="preserve">
<value>Expression is %1, Current input is %2</value>
<comment>{Locked="%1","%2"}. Screen reader prompt for the Calculator always-on-top expression. %1 = Expression, e.g. "50 + 2 - 60 +", %2 = Localized display value, e.g. "50".</comment>
</data>
<data name="Format_CalculatorResults_Decimal" xml:space="preserve">
<value>Display is %1 point</value>
<comment>{Locked="%1"}. Automation label for the calculator display in the specific case where the user has just pressed the decimal separator button. For example, the user wants to input "7.5". When they have input "7." they will hear "Display is 7 point". "point" should be localized to the locale's appropriate decimal separator.</comment>
@ -1271,7 +1275,7 @@
</data>
<data name="equalButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Equals</value>
<comment>Screen reader prompt for the equals button on the scientific operator keypad</comment>
<comment>Screen reader prompt for the invert button on the scientific operator keypad</comment>
</data>
<data name="shiftButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Inverse Function</value>
@ -1469,6 +1473,22 @@
<value>Categories DropDown</value>
<comment>Screen reader prompt for the Categories dropdown field.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Keep on top</value>
<comment>Screen reader prompt for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name" xml:space="preserve">
<value>Back to full view</value>
<comment>Screen reader prompt for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="EnterAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Keep on top</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in normal mode.</comment>
</data>
<data name="ExitAlwaysOnTopButton.[using:Windows.UI.Xaml.Controls]ToolTipService.ToolTip" xml:space="preserve">
<value>Back to full view</value>
<comment>This is the tool tip automation name for the Always-on-Top button when in Always-on-Top mode.</comment>
</data>
<data name="Format_ValueFrom" xml:space="preserve">
<value>Convert from %1 %2</value>
<comment>Screen reader prompt for the Unit Converter Value1 i.e. top number field. %1 = DisplayValue, %2 = Unit field localized name.</comment>

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше