Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: auto load qt translations #212

Closed
wants to merge 1 commit into from

Conversation

kegechen
Copy link
Contributor

Normally, Qt applications need to explicitly load translations by themselves, including Qt translations. Here we take the initiative to help applications that have loaded dtk (including plugins) load translations.

Issue: linuxdeepin/developer-center#6417

Normally, Qt applications need to explicitly load translations by themselves,
including Qt translations. Here we take the initiative to help applications
that have loaded dtk (including plugins) load translations.

Issue: linuxdeepin/developer-center#6417
@deepin-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: kegechen

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

deepin-ci-robot added a commit to linuxdeepin/dtk6gui that referenced this pull request Dec 15, 2023
Synchronize source files from linuxdeepin/dtkgui.

Source-pull-request: linuxdeepin/dtkgui#212
@deepin-bot
Copy link
Contributor

deepin-bot bot commented Dec 15, 2023

Doc Check bot
🟢 Document Coverage Check Passed!


// load qt/qtbase translation for qt app which load dtk ?
QTimer::singleShot(0, [](){
DGuiApplicationHelper::loadTranslator();
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

可能会重复加载,应用再加载的话

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

让应用自己加载不就行了,否则在非DDE、非KDE环境上应用程序怎么办?这本来就是一个没有保障的事情。

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

那就要到输入法插件改了。


// load qt/qtbase translation for qt app which load dtk ?
QTimer::singleShot(0, [](){
DGuiApplicationHelper::loadTranslator();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

让应用自己加载不就行了,否则在非DDE、非KDE环境上应用程序怎么办?这本来就是一个没有保障的事情。

@kegechen
Copy link
Contributor Author

输入法插件改

@kegechen kegechen closed this Dec 18, 2023
kegechen pushed a commit to linuxdeepin/dtk6gui that referenced this pull request Dec 20, 2023
Synchronize source files from linuxdeepin/dtkgui.

Source-pull-request: linuxdeepin/dtkgui#212
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants