/* -*- 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 . */ #pragma once #include #include namespace com::sun::star { namespace security { class XCertificate; } namespace xml::crypto { class XSecurityEnvironment; } } namespace com::sun::star::xml::crypto { class XXMLSecurityContext; } struct UserData { css::uno::Reference xCertificate; css::uno::Reference xSecurityContext; css::uno::Reference xSecurityEnvironment; }; enum class UserAction { Sign, SelectSign, // Select signing certificate Encrypt }; class CertificateChooser final : public weld::GenericDialogController { private: std::vector< css::uno::Reference< css::xml::crypto::XXMLSecurityContext > > mxSecurityContexts; std::vector> mvUserData; bool mbInitialized; UserAction const meAction; OUString msPreferredKey; css::uno::Reference mxEncryptToSelf; std::unique_ptr m_xFTSign; std::unique_ptr m_xFTEncrypt; std::unique_ptr m_xCertLB; std::unique_ptr m_xViewBtn; std::unique_ptr m_xOKBtn; std::unique_ptr m_xFTDescription; std::unique_ptr m_xDescriptionED; DECL_LINK(ViewButtonHdl, weld::Button&, void); DECL_LINK(CertificateHighlightHdl, weld::TreeView&, void); DECL_LINK(CertificateSelectHdl, weld::TreeView&, bool); void ImplShowCertificateDetails(); void ImplInitialize(); static void HandleOneUsageBit(OUString& string, int& bits, int bit, const char *name); public: CertificateChooser(weld::Window* pParent, std::vector< css::uno::Reference< css::xml::crypto::XXMLSecurityContext > > const & rxSecurityContexts, UserAction eAction); virtual ~CertificateChooser() override; short run() override; css::uno::Sequence > GetSelectedCertificates(); css::uno::Reference< css::xml::crypto::XXMLSecurityContext > GetSelectedSecurityContext() const; /// Gets the description string provided when selecting the certificate. OUString GetDescription() const; /// Returns the usage string of the selected certificate, if any. OUString GetUsageText(); static OUString UsageInClearText(int bits); }; /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ bora/cp-4.2'>distro/collabora/cp-4.2 LibreOffice 核心代码仓库文档基金会
summaryrefslogtreecommitdiff
AgeCommit message (Expand)Author
2024-11-13tdf#163486: PVS: variable is used after being declaredXisco Fauli
2024-11-13tdf#163486: PVS: variable is used after being declaredXisco Fauli
2024-05-10loplugin:ostr in ooxNoel Grandin
2023-12-01[API CHANGE] Add OOXML way of curved connector routingRegina Henschel
2023-11-15Fix typoAndrea Gelmini
2023-11-15Fix typoAndrea Gelmini
2023-11-15Import Wordprocessing Canvas, wpc:wpc elementRegina Henschel
2023-04-08oox: add model::Theme to oox::Theme and remove createSvxThemeTomaž Vajngerl
2023-03-01oox: import directly into docmodel's Theme and ColorSetTomaž Vajngerl
2023-01-01sw: read theme from OOXML file and set it to the draw pageTomaž Vajngerl
2022-12-21Use rtl::Reference to avoid some dynamic_castsStephan Bergmann
2022-10-28tdf#54095 docx SmartArt import, apply theme text colorRegina Henschel
2022-10-24tdf#83671 make SmartArt visible in import of xlsxRegina Henschel
2022-10-13tdf#149840 Use actual outer size for SmartArt in WriterRegina Henschel
2022-08-02clang-tidy modernize-pass-by-value in ooxNoel Grandin
2022-02-25Advanced Diagram support: cleanup/consolidate with existing codeArmin Le Grand (Allotropia)
2022-02-03tdf#146802 OOXML import: fix embedded VML in grouped textboxAttila Bakos (NISZ)
2022-01-30Recheck modules [o-r]* with IWYUGabor Kelemen
2022-01-03tdf#143574 OOXML export/import of textboxes in group shapesAttila Bakos (NISZ)
2021-08-19loplugin:constmethodsNoel Grandin
2021-07-01loplugin:unusedmethodsNoel Grandin
2021-06-29tdf#135316 share themePtr and ShapeFilterBase across all shapesNoel Grandin
2021-06-29remove try/catch in ShapeContextHandler constructorNoel Grandin
2021-06-28[API CHANGE] drop ShapeContextHandler service and interfaceNoel Grandin
2021-06-28store actual type in ShapeFragmentHandler::mxFilterBaseNoel Grandin
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann
2020-11-03tdf#128877 DOCX import: fix lost position of image cropped to shapeMiklos Vajna
2020-09-25fix Graphic duplication in import and add GraphicMapperTomaž Vajngerl
2020-06-03loplugin:simplifypointertobool improveNoel Grandin
2020-04-03loplugin:flatten in ooxNoel Grandin
2020-03-09tdf#42949 Fix IWYU warnings in oox/*/*hxxGabor Kelemen
2020-01-26remove some unused local varsNoel Grandin
2020-01-24loplugin:makeshared in ooxNoel Grandin
2020-01-15clang-tidy modernize-concat-nested-namespace in ooxNoel Grandin
2020-01-14tdf#129516 DOCX import: fix incorrect z-order with textboxesMiklos Vajna
2020-01-13tdf#88205 Adapt uses of css::uno::Sequence to use initializer_list ctorMesut Çifci
2020-01-10use more std::make_sharedNoel Grandin
2019-11-13tdf#117658 PPTX import: fix duplicated math object handlingMiklos Vajna
2019-07-31Improved loplugin:stringconstant (now that GCC 7 supports it): ooxStephan Bergmann
2019-07-20loplugin:referencecasting in oox..pyunoNoel Grandin
2019-05-10SmartArt: support diagram backgroundGrzegorz Araminowicz
2019-03-31tdf#120703 PVS: remove redundant static castsMike Kaganski
2019-03-18PPTX import: save also OOXDrawing in InteropGrabBagGrzegorz Araminowicz
2019-01-08convert "*xxx.get()" to "*xxx"Noel Grandin
2019-01-07related tdf#100074: prepare group shapes text input via writerfilterThorsten Behrens
2018-09-28oox: create ShapeContextHandler instances with an uno constructorMiklos Vajna
2018-03-31Use for-range loops in oox (part2)Julien Nabet
2017-12-11loplugin:salcall fix functionsNoel Grandin
2017-10-23loplugin:includeform: ooxStephan Bergmann
2017-07-13use more OUString::operator== in forms..salNoel Grandin