mirror of
https://github.com/leonboe1/QuickDrop.git
synced 2026-11-12 11:31:09 +00:00
Add option to choose save directory & automatically accept files
This commit is contained in:
1 parent
164d351c4d
commit
ea324ea7d8
26 files changed
+436
-77
No files matched your search
+38
-21
@@ -21,28 +21,9 @@ struct TutorialView: View {
|
||||
@AppStorage(UserDefaultsKeys.plusVersion.rawValue) var isPlusVersion = false
|
||||
|
||||
var body: some View {
|
||||
ScrollView {
|
||||
|
||||
|
||||
LargeAppIconView(title: title) {
|
||||
VStack {
|
||||
Image("AppIconHighRes")
|
||||
.resizable()
|
||||
.frame(width: 150, height: 150)
|
||||
.padding(.top, 50)
|
||||
.onTapGesture {
|
||||
taps += 1
|
||||
print("Tapped \(taps) times")
|
||||
|
||||
if taps == 5 {
|
||||
let logString = LogManager.sharedInstance.getLogString()
|
||||
copyToClipboard(logString)
|
||||
print("Copied log to clipboard")
|
||||
}
|
||||
}
|
||||
|
||||
Text(title.localized())
|
||||
.font(.largeTitle)
|
||||
.padding()
|
||||
|
||||
Text(text.localized())
|
||||
.multilineTextAlignment(.center)
|
||||
.fixedSize(horizontal: false, vertical: true)
|
||||
@@ -90,6 +71,42 @@ struct TutorialView: View {
|
||||
.padding()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
struct LargeAppIconView<Content: View>: View {
|
||||
|
||||
let title: String
|
||||
let bottomView: () -> Content
|
||||
@State var taps = 0
|
||||
|
||||
var body: some View {
|
||||
ScrollView {
|
||||
|
||||
VStack {
|
||||
Image("AppIconHighRes")
|
||||
.resizable()
|
||||
.frame(width: 150, height: 150)
|
||||
.padding(.top, 50)
|
||||
.onTapGesture {
|
||||
taps += 1
|
||||
print("Tapped \(taps) times")
|
||||
|
||||
if taps == 5 {
|
||||
let logString = LogManager.sharedInstance.getLogString()
|
||||
copyToClipboard(logString)
|
||||
print("Copied log to clipboard")
|
||||
}
|
||||
}
|
||||
|
||||
Text(title.localized())
|
||||
.font(.largeTitle)
|
||||
.padding()
|
||||
|
||||
bottomView()
|
||||
}
|
||||
.frame(maxWidth: 500)
|
||||
.frame(maxWidth: .infinity)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user