Hi,
so I have a simple app, that lists out available peripheral names. It found for example my iPad, but if I want to change the name to whatever else, it's still showing the old name. Is there any way to refresh it?
Thanks a lot
Post
Replies
Boosts
Views
Activity
Hi, is there any possibility to control iPhone over Raspberry's Bluetooth? For example, when I press button, iPhone will stop playing music. Thanks a lot!
Hi, as you can see, I'm loading json data from server. Sometimes when I click on Navigation Link, it shows this gray are... any help? Thanks!
The variable from SignInController changes, the view does not.
import SwiftUI
import Foundation
class SignInController: ObservableObject {
var signedIn: Bool = false
}
struct MainView: View {
@StateObject var signCon = SignInController()
var body: some View {
return Group {
if signCon.signedIn == false {
ZStack {
SignView()
Button {
signCon.signedIn.toggle()
print(signCon.signedIn)
} label: {
Text("Make True")
}
}
}
else if signCon.signedIn == true {
HomeView()
}
}
}
}
struct MainView_Previews: PreviewProvider {
static var previews: some View {
MainView()
}
}
extension UserDefaults {
func valueExists(forKey key: String) -> Bool {
return object(forKey: key) != nil
}
}
Hi, I'm trying to do basic app with fixed Navigation View on iPad. Doesn't work. What am I doing wrong?
import SwiftUI
struct CollectionView: View {
var body: some View {
if #available(iOS 15.0, *) {
NavigationView {
Text("Hello")
.navigationTitle("Hello")
}
.navigationViewStyle(.columns)
.padding()
} else {
// Fallback on earlier versions
}
}
}
struct CollectionView_Previews: PreviewProvider {
static var previews: some View {
CollectionView()
}
}
Hi, trying simply using new ColumnNavigationViewStyle and getting error in title on using it.
struct CollectionView: View {
var body: some View {
NavigationView {
Text("Hello")
.navigationTitle("Hello")
}
.navigationViewStyle(ColumnNavigationViewStyle())
}
}
struct CollectionView_Previews: PreviewProvider {
static var previews: some View {
CollectionView()
}
}