replace createFromAscii with OUString literals in toolkit

Change-Id: I039ee0068cdd8640678524079dd60540abbf876c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167126
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
This commit is contained in:
Noel Grandin 2024-05-02 15:34:30 +02:00
parent b9cc4575c6
commit f221ccd6dc
5 changed files with 5 additions and 28 deletions

View file

@ -126,7 +126,6 @@ $(eval $(call gb_Library_add_exception_objects,tk,\
toolkit/source/helper/imagealign \
toolkit/source/helper/listenermultiplexer \
toolkit/source/helper/property \
toolkit/source/helper/servicenames \
toolkit/source/helper/tkresmgr \
toolkit/source/helper/unopropertyarrayhelper \
toolkit/source/helper/unowrapper \

View file

@ -19,6 +19,8 @@
#pragma once
extern const char szServiceName_UnoControlDialog[];
#include <rtl/ustring.hxx>
inline constexpr OUString sServiceName_UnoControlDialog = u"stardiv.vcl.control.Dialog"_ustr;
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */

View file

@ -165,7 +165,7 @@ Any ControlModelContainerBase::ImplGetDefaultValue( sal_uInt16 nPropId ) const
switch ( nPropId )
{
case BASEPROPERTY_DEFAULTCONTROL:
aAny <<= OUString::createFromAscii( szServiceName_UnoControlDialog );
aAny <<= sServiceName_UnoControlDialog;
break;
default:
aAny = UnoControlModel::ImplGetDefaultValue( nPropId );

View file

@ -239,7 +239,7 @@ Any UnoControlDialogModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
switch ( nPropId )
{
case BASEPROPERTY_DEFAULTCONTROL:
aAny <<= OUString::createFromAscii( szServiceName_UnoControlDialog );
aAny <<= sServiceName_UnoControlDialog;
break;
case BASEPROPERTY_SCROLLWIDTH:
case BASEPROPERTY_SCROLLHEIGHT:

View file

@ -1,24 +0,0 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
* This file is part of the LibreOffice project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* This file incorporates work covered by the following license notice:
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed
* with this work for additional information regarding copyright
* ownership. The ASF licenses this file to you under the Apache
* License, Version 2.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
#include <helper/servicenames.hxx>
const char szServiceName_UnoControlDialog[] = "stardiv.vcl.control.Dialog";
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */