Skip to content

Commit

Permalink
Revert "Feautre tips view (#418)" (#477)
Browse files Browse the repository at this point in the history
This reverts commit 074bb73.
  • Loading branch information
tisfeng authored Mar 30, 2024
1 parent a86f56c commit 11fd868
Show file tree
Hide file tree
Showing 17 changed files with 8 additions and 617 deletions.
6 changes: 0 additions & 6 deletions Easydict.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,6 @@
9672D7D22B4008B40023B8FB /* MASShortcutBinder+EZMASShortcutBinder.m in Sources */ = {isa = PBXBuildFile; fileRef = 9672D7D12B4008B40023B8FB /* MASShortcutBinder+EZMASShortcutBinder.m */; };
967712EA2B5B913600105E0F /* KeyHolder in Frameworks */ = {isa = PBXBuildFile; productRef = 967712E92B5B913600105E0F /* KeyHolder */; };
967712EE2B5B943400105E0F /* Shortcut.swift in Sources */ = {isa = PBXBuildFile; fileRef = 967712ED2B5B943400105E0F /* Shortcut.swift */; };
96DFEB832B82588000F5C7EF /* EZTableTipsCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 96DFEB822B82588000F5C7EF /* EZTableTipsCell.m */; };
A0B65CA0F31AC8ECFB8347CC /* Pods_EasydictTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 378E73A7EA8FC8FB9C975A63 /* Pods_EasydictTests.framework */; };
B87AC7E36367075BA5D13234 /* Pods_Easydict.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6372B33DFF803C7096A82250 /* Pods_Easydict.framework */; };
C415C0AD2B450D4800A9D231 /* GeminiService.swift in Sources */ = {isa = PBXBuildFile; fileRef = C415C0AC2B450D4800A9D231 /* GeminiService.swift */; };
Expand Down Expand Up @@ -826,8 +825,6 @@
9672D7D02B4008B40023B8FB /* MASShortcutBinder+EZMASShortcutBinder.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "MASShortcutBinder+EZMASShortcutBinder.h"; sourceTree = "<group>"; };
9672D7D12B4008B40023B8FB /* MASShortcutBinder+EZMASShortcutBinder.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "MASShortcutBinder+EZMASShortcutBinder.m"; sourceTree = "<group>"; };
967712ED2B5B943400105E0F /* Shortcut.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Shortcut.swift; sourceTree = "<group>"; };
96DFEB812B82588000F5C7EF /* EZTableTipsCell.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = EZTableTipsCell.h; sourceTree = "<group>"; };
96DFEB822B82588000F5C7EF /* EZTableTipsCell.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = EZTableTipsCell.m; sourceTree = "<group>"; };
A230E9A2358C7FBC7FB26189 /* Pods-EasydictTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-EasydictTests.debug.xcconfig"; path = "Target Support Files/Pods-EasydictTests/Pods-EasydictTests.debug.xcconfig"; sourceTree = "<group>"; };
C415C0AC2B450D4800A9D231 /* GeminiService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GeminiService.swift; sourceTree = "<group>"; };
C4DD01E82B12B3C80025EE8E /* TencentService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TencentService.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -1505,8 +1502,6 @@
children = (
0396D60F292C932F006A11D9 /* EZSelectLanguageCell.h */,
0396D610292C932F006A11D9 /* EZSelectLanguageCell.m */,
96DFEB812B82588000F5C7EF /* EZTableTipsCell.h */,
96DFEB822B82588000F5C7EF /* EZTableTipsCell.m */,
037852B7295D49F900D0E2CF /* EZTableRowView.h */,
037852B8295D49F900D0E2CF /* EZTableRowView.m */,
);
Expand Down Expand Up @@ -3013,7 +3008,6 @@
03B022FE29231FA6001C7E63 /* EZBaseQueryViewController.m in Sources */,
DC6D9C892B3969510055EFFC /* Appearance.swift in Sources */,
0396D611292C932F006A11D9 /* EZSelectLanguageCell.m in Sources */,
96DFEB832B82588000F5C7EF /* EZTableTipsCell.m in Sources */,
036196752A000F5900806370 /* FWEncryptorAES.m in Sources */,
9643D9462B71D103000FBEA6 /* KeyHolderRowView.swift in Sources */,
0399C6A829A74E0F00B4AFCC /* EZQueryResult+EZDeepLTranslateResponse.m in Sources */,
Expand Down
22 changes: 0 additions & 22 deletions Easydict/App/Assets.xcassets/tip_Normal.imageset/Contents.json

This file was deleted.

Binary file not shown.
Binary file not shown.
203 changes: 0 additions & 203 deletions Easydict/App/Localizable.xcstrings
Original file line number Diff line number Diff line change
Expand Up @@ -986,23 +986,6 @@
}
}
},
"disable_tips_view" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Disable Tips View"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "关闭提示视图"
}
}
}
},
"disabled_app_list" : {
"comment" : "disabled app list",
"localizations" : {
Expand Down Expand Up @@ -4298,192 +4281,6 @@
}
}
},
"tips_beep" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why is there a beep when the selected word is empty (such as dragging in a blank area) in some applications?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "为什么在某些应用取词为空(空白处拖动等)时会出现提示音?"
}
}
}
},
"tips_edit_button" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why does the edit button in the upper right corner flicker when selecting words in some applications?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "为什么在某些应用取词时,右上角编辑按钮会出现闪烁?"
}
}
}
},
"tips_might_selecting" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why might selecting an empty word interrupt the music currently playing?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "为什么取词为空时可能打断当前播放的音乐?"
}
}
}
},
"tips_more" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "See More"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "查看更多"
}
}
}
},
"tips_mouse_hover" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why can't I use mouse hover to select words in some applications?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "为什么在某些应用中无法使用鼠标划词?"
}
}
}
},
"tips_select_words" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why can't I select words on some web pages in the browser?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "为什么浏览器中某些网页无法取词?"
}
}
}
},
"tips_solve" : {
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Solve This"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "如何解决"
}
}
}
},
"tips_still_pop_up" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why does macOS still pop up asking for permissions even though I have given Easydict the Accessibility/Screen Recording permissions?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "已经给 Easydict 辅助功能/录屏权限 macOS 仍然弹窗要求给予权限?"
}
}
}
},
"tips_text_empty" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why is the text empty when I select words in some applications?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "为什么在某些应用中取词文本为空?"
}
}
}
},
"tips_title" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Tips"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "提示"
}
}
}
},
"tips_word_selection_OCR" : {
"extractionState" : "manual",
"localizations" : {
"en" : {
"stringUnit" : {
"state" : "translated",
"value" : "Why do word selection and OCR need to enable system-related permissions?"
}
},
"zh-Hans" : {
"stringUnit" : {
"state" : "translated",
"value" : "为什么取词和 OCR 需要开启系统相关权限?"
}
}
}
},
"Tisfeng" : {
"localizations" : {
"zh-Hans" : {
Expand Down
2 changes: 0 additions & 2 deletions Easydict/Feature/Configuration/Configuration.swift
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,6 @@ class Configuration: NSObject {

@DefaultsWrapper(.selectQueryTextWhenWindowActivate) var selectQueryTextWhenWindowActivate: Bool

@DefaultsWrapper(.disableTipsView) var disableTipsView: Bool

var disabledAutoSelect: Bool = false

var isRecordingSelectTextShortcutKey: Bool = false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,11 +156,6 @@ static NSArray *const EZDashCharacterList = @[ @"—", @"-", @"–" ];

- (NSString *)removeAlphabetAndNumbers;

#pragma mark - Check Empty String
#ifndef EZ_isEmptyString
FOUNDATION_EXPORT BOOL EZ_isEmptyString(id param);
#endif

@end

NS_ASSUME_NONNULL_END
17 changes: 2 additions & 15 deletions Easydict/Feature/Utility/EZCategory/NSString/NSString+EZUtils.m
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,6 @@
@"" : @"",
};

BOOL EZ_isEmptyString(id param) {
if (!param) {
return YES;
}
if ([param isKindOfClass:[NSString class]]) {
NSString *str = param;
return (str.length == 0);
}
NSCAssert(NO, @"isEmptyString: param %@ is not NSString", param);
return YES;
}


@implementation NSString (EZUtils)

/// Check if it is a single letter of the alphabet, like 'a', 'A'
Expand Down Expand Up @@ -237,7 +224,7 @@ - (BOOL)isEnglishWordWithLanguage:(EZLanguage)language {
}

- (NLLanguage)detectText {
NLTagger *tagger = [[NLTagger alloc] initWithTagSchemes:@[ NLTagSchemeLanguage ]];
NLTagger *tagger = [[NLTagger alloc] initWithTagSchemes:@[NLTagSchemeLanguage]];
tagger.string = self;
NLLanguage language = [tagger dominantLanguage];
return language;
Expand Down Expand Up @@ -479,7 +466,7 @@ - (NSString *)suffixQuote {
}
return quotes;
}


- (NSString *)tryToRemovePrefixQuote {
NSString *prefixQuote = [self prefixQuote];
Expand Down
19 changes: 0 additions & 19 deletions Easydict/Feature/ViewController/Cell/EZTableTipsCell.h

This file was deleted.

Loading

0 comments on commit 11fd868

Please sign in to comment.