Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
SMillerDev committed Jan 27, 2025
1 parent 3c6eb14 commit 52fffbf
Show file tree
Hide file tree
Showing 13 changed files with 87 additions and 174 deletions.
12 changes: 9 additions & 3 deletions Fosdem.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
92CE31B128FC4A940073813E /* EventListView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92CE31B028FC4A940073813E /* EventListView.swift */; };
92D9E7B8291D7B9B007D203D /* HTMLFormattedText.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92D9E7B7291D7B9B007D203D /* HTMLFormattedText.swift */; };
92D9E7BA291D95E1007D203D /* EventDetailHeader.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92D9E7B9291D95E1007D203D /* EventDetailHeader.swift */; };
92E5C1152D4820A60017CEE0 /* ListPredicateType.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92E5C1142D4820A60017CEE0 /* ListPredicateType.swift */; };
92F70AA02922B49A000BE6CB /* UrlHelper.swift in Sources */ = {isa = PBXBuildFile; fileRef = 92F70A9F2922B49A000BE6CB /* UrlHelper.swift */; };
/* End PBXBuildFile section */

Expand Down Expand Up @@ -116,6 +117,8 @@
92CE31B028FC4A940073813E /* EventListView.swift */ = {isa = PBXFileReference; explicitFileType = sourcecode.swift; path = EventListView.swift; sourceTree = "<group>"; };
92D9E7B7291D7B9B007D203D /* HTMLFormattedText.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HTMLFormattedText.swift; sourceTree = "<group>"; };
92D9E7B9291D95E1007D203D /* EventDetailHeader.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EventDetailHeader.swift; sourceTree = "<group>"; };
92E5C1142D4820A60017CEE0 /* ListPredicateType.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ListPredicateType.swift; sourceTree = "<group>"; };
92E5C1162D4822DF0017CEE0 /* README.md */ = {isa = PBXFileReference; lastKnownFileType = net.daringfireball.markdown; path = README.md; sourceTree = "<group>"; };
92F70A9F2922B49A000BE6CB /* UrlHelper.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UrlHelper.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */

Expand Down Expand Up @@ -184,16 +187,14 @@
925B0260298EAE0E00AFA83D /* LiveIcon.swift */,
925B0262298EB2A400AFA83D /* VideoPlayer.swift */,
9268D799298F251E0067A6B1 /* ListSettings.swift */,
92BD1D2D2B5C345700DB8FC1 /* EventTypeIcon.swift */,
92BD1D2F2B5C34F100DB8FC1 /* EventTypeColor.swift */,
92BD1D312B5C374A00DB8FC1 /* TrackColor.swift */,
);
path = Views;
sourceTree = "<group>";
};
14D2770C2205D07200740042 = {
isa = PBXGroup;
children = (
92E5C1162D4822DF0017CEE0 /* README.md */,
925F4A7C2B285A70007E9D1D /* Localizable.xcstrings */,
92A57B392988FD1C00C0BB78 /* Package.swift */,
92A2BDF92948CC5E0034864F /* FosdemTests.xctestplan */,
Expand Down Expand Up @@ -225,6 +226,10 @@
14D277242205D07500740042 /* Assets.xcassets */,
14D277292205D07500740042 /* Info.plist */,
92C22E6129806F61006D7B5C /* privacy.md */,
92E5C1142D4820A60017CEE0 /* ListPredicateType.swift */,
92BD1D2D2B5C345700DB8FC1 /* EventTypeIcon.swift */,
92BD1D2F2B5C34F100DB8FC1 /* EventTypeColor.swift */,
92BD1D312B5C374A00DB8FC1 /* TrackColor.swift */,
);
path = Fosdem;
sourceTree = "<group>";
Expand Down Expand Up @@ -474,6 +479,7 @@
92F70AA02922B49A000BE6CB /* UrlHelper.swift in Sources */,
9290384C2C9613FD002201FC /* ScheduleFetchingActor.swift in Sources */,
92D9E7B8291D7B9B007D203D /* HTMLFormattedText.swift in Sources */,
92E5C1152D4820A60017CEE0 /* ListPredicateType.swift in Sources */,
142A87442224752E0034F6D7 /* EventType.swift in Sources */,
92BD1D322B5C374A00DB8FC1 /* TrackColor.swift in Sources */,
);
Expand Down
File renamed without changes.
File renamed without changes.
48 changes: 0 additions & 48 deletions Fosdem/Import/XmlFinder.swift

This file was deleted.

41 changes: 41 additions & 0 deletions Fosdem/ListPredicateType.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
//
// ListPredicateType.swift
// Fosdem
//
// Created by Sean Molenaar on 27/01/2025.
// Copyright © 2025 Sean Molenaar. All rights reserved.
//

import Foundation

enum ListPredicateType {
case person
case room
case track

static var all: [ListPredicateType] {
return [.track, .person, .room]
}

static func getName(_ type: ListPredicateType) -> String {
switch type {
case .person:
return String(localized: "People")
case .room:
return String(localized: "Rooms")
case .track:
return String(localized: "Tracks")
}
}

static func getIcon(_ type: ListPredicateType) -> String {
switch type {
case .person:
return "person"
case .room:
return "door.left.hand.open"
case .track:
return "road.lanes"
}
}
}
2 changes: 1 addition & 1 deletion Fosdem/Models/Event.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public class Event {

public var room: Room
public var track: Track!
public var type: EventType?
public var type: EventType!

public var userInfo: EventUserInfo?

Expand Down
2 changes: 2 additions & 0 deletions Fosdem/Models/Link.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ public class Link {
public var isVideo: Bool {
return type.contains(/video/) || name.lowercased().contains(/video recording/)
}

@Transient
public var isStreamableVideo: Bool {
return url.absoluteString.contains(/\.mp4$/)
}
Expand Down
17 changes: 0 additions & 17 deletions Fosdem/Models/ManagedObjectProtocol.swift

This file was deleted.

File renamed without changes.
72 changes: 0 additions & 72 deletions Fosdem/Views/ListPredicate.swift

This file was deleted.

34 changes: 34 additions & 0 deletions Fosdem/Views/ListPredicateType.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import Foundation
import SwiftUI

enum ListPredicateType {
case person
case room
case track

static var all: [ListPredicateType] {
return [.track, .person, .room]
}

static func getName(_ type: ListPredicateType) -> String {
switch type {
case .person:
return "People"
case .room:
return "Rooms"
case .track:
return "Tracks"
}
}

static func getIcon(_ type: ListPredicateType) -> String {
switch type {
case .person:
return "person"
case .room:
return "door.left.hand.open"
case .track:
return "road.lanes"
}
}
}
32 changes: 0 additions & 32 deletions Fosdem/Views/ListSettings.swift
Original file line number Diff line number Diff line change
Expand Up @@ -92,35 +92,3 @@ class ListSettings: ObservableObject {
return predicate
}
}

enum ListPredicateType {
case person
case room
case track

static var all: [ListPredicateType] {
return [.track, .person, .room]
}

static func getName(_ type: ListPredicateType) -> String {
switch type {
case .person:
return "People"
case .room:
return "Rooms"
case .track:
return "Tracks"
}
}

static func getIcon(_ type: ListPredicateType) -> String {
switch type {
case .person:
return "person"
case .room:
return "door.left.hand.open"
case .track:
return "road.lanes"
}
}
}
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,3 @@ Store: https://apps.apple.com/nl/app/fosdem-helper/id1667646664

## TODO:
- People links
- Livestream view

0 comments on commit 52fffbf

Please sign in to comment.