mirror of
https://github.com/dscyrescotti/Memola.git
synced 2026-07-16 09:43:02 +02:00
feat: add find keyboard shortcut
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
//
|
||||
// NavigationSplitViewVisibility++.swift
|
||||
// Memola
|
||||
//
|
||||
// Created by Dscyre Scotti on 7/14/24.
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
|
||||
extension NavigationSplitViewVisibility: RawRepresentable {
|
||||
public init?(rawValue: Int) {
|
||||
switch rawValue {
|
||||
case 0: self = .all
|
||||
case 1: self = .automatic
|
||||
case 2: self = .detailOnly
|
||||
case 3: self = .doubleColumn
|
||||
default: self = .all
|
||||
}
|
||||
}
|
||||
|
||||
public var rawValue: Int {
|
||||
switch self {
|
||||
case .all: 0
|
||||
case .automatic: 1
|
||||
case .detailOnly: 2
|
||||
case .doubleColumn: 3
|
||||
default: -1
|
||||
}
|
||||
}
|
||||
|
||||
public typealias RawValue = Int
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user