Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
KDE PIM Add-ons
Commits
79e78308
Commit
79e78308
authored
Aug 06, 2020
by
Laurent Montel
😁
Browse files
Allow to import several contacts
parent
a9e7aff1
Pipeline
#29849
failed with stage
in 110 minutes and 35 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
kaddressbook/importexportplugins/windows-contacts/windowscontactimportexportplugininterface.cpp
View file @
79e78308
...
...
@@ -90,17 +90,19 @@ void WindowsContactImportExportPluginInterface::exec()
void
WindowsContactImportExportPluginInterface
::
importWindowsContact
()
{
const
QString
fileName
=
QFileDialog
::
getOpenFileName
(
parentWidget
(),
QString
(),
QDir
::
homePath
(),
i18n
(
"Windows Contact file (*.contact)"
));
const
QString
List
fileName
s
=
QFileDialog
::
getOpenFileName
s
(
parentWidget
(),
QString
(),
QDir
::
homePath
(),
i18n
(
"Windows Contact file (*.contact)"
));
if
(
fileName
.
isEmpty
())
{
if
(
fileName
s
.
isEmpty
())
{
return
;
}
KContacts
::
Addressee
::
List
addresseeList
;
ImportWindowContact
importer
;
importer
.
setParentWidget
(
parentWidget
());
addresseeList
=
importer
.
importFile
(
fileName
);
for
(
const
QString
&
fileName
:
fileNames
)
{
addresseeList
.
append
(
importer
.
importFile
(
fileName
));
}
KAddressBookImportExport
::
KAddressBookImportExportContactList
contactList
;
contactList
.
setAddressList
(
addresseeList
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment