Skip to content

Commit 527ad65

Browse files
committed
Update resources usage for cocoapods support
1 parent 7f2c536 commit 527ad65

File tree

2 files changed

+403
-10
lines changed

2 files changed

+403
-10
lines changed

Keyboard/DefaultKeyboard/DefaultKeyboardLayout.swift

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ public enum DefaultKeyboardLayout {
137137
style: DefaultKeyboardRowStyle,
138138
characters: [
139139
KeyboardButton(
140-
type: .Image(UIImage(named: toggled ? "shiftToggled" : "shiftToggledOnce")),
140+
type: .Image(UIImage(named: toggled ? "shiftToggled" : "shiftToggledOnce", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
141141
style: DefaultKeyboardShiftButtonStyle,
142142
width: .Relative(percent: 0.13),
143143
identifier: toggled ? DefaultKeyboardIdentifier.ShiftToggled.rawValue : DefaultKeyboardIdentifier.ShiftToggledOnce.rawValue),
@@ -154,7 +154,7 @@ public enum DefaultKeyboardLayout {
154154
]
155155
),
156156
KeyboardButton(
157-
type: .Image(UIImage(named: "backspace")),
157+
type: .Image(UIImage(named: "backspace", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
158158
style: DefaultKeyboardBackspaceButtonStyle,
159159
width: .Relative(percent: 0.13),
160160
identifier: DefaultKeyboardIdentifier.Backspace.rawValue),
@@ -169,7 +169,7 @@ public enum DefaultKeyboardLayout {
169169
width: .Relative(percent: 0.13),
170170
identifier: DefaultKeyboardIdentifier.Numbers.rawValue),
171171
KeyboardButton(
172-
type: .Image(UIImage(named: "globe")),
172+
type: .Image(UIImage(named: "globe", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
173173
style: DefaultKeyboardGlobeButtonStyle,
174174
width: .Static(width: 40),
175175
identifier: DefaultKeyboardIdentifier.Globe.rawValue),
@@ -225,7 +225,7 @@ public enum DefaultKeyboardLayout {
225225
style: DefaultKeyboardRowStyle,
226226
characters: [
227227
KeyboardButton(
228-
type: .Image(UIImage(named: "shift")),
228+
type: .Image(UIImage(named: "shift", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
229229
style: DefaultKeyboardShiftButtonStyle,
230230
width: .Relative(percent: 0.13),
231231
identifier: DefaultKeyboardIdentifier.Shift.rawValue),
@@ -242,7 +242,7 @@ public enum DefaultKeyboardLayout {
242242
]
243243
),
244244
KeyboardButton(
245-
type: .Image(UIImage(named: "backspace")),
245+
type: .Image(UIImage(named: "backspace", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
246246
style: DefaultKeyboardBackspaceButtonStyle,
247247
width: .Relative(percent: 0.13),
248248
identifier: DefaultKeyboardIdentifier.Backspace.rawValue),
@@ -257,7 +257,7 @@ public enum DefaultKeyboardLayout {
257257
width: .Relative(percent: 0.13),
258258
identifier: DefaultKeyboardIdentifier.Numbers.rawValue),
259259
KeyboardButton(
260-
type: .Image(UIImage(named: "globe")),
260+
type: .Image(UIImage(named: "globe", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
261261
style: DefaultKeyboardGlobeButtonStyle,
262262
width: .Static(width: 40),
263263
identifier: DefaultKeyboardIdentifier.Globe.rawValue),
@@ -329,7 +329,7 @@ public enum DefaultKeyboardLayout {
329329
]
330330
),
331331
KeyboardButton(
332-
type: .Image(UIImage(named: "backspace")),
332+
type: .Image(UIImage(named: "backspace", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
333333
style: DefaultKeyboardBackspaceButtonStyle,
334334
width: .Relative(percent: 0.13),
335335
identifier: DefaultKeyboardIdentifier.Backspace.rawValue),
@@ -344,7 +344,7 @@ public enum DefaultKeyboardLayout {
344344
width: .Relative(percent: 0.13),
345345
identifier: DefaultKeyboardIdentifier.Letters.rawValue),
346346
KeyboardButton(
347-
type: .Image(UIImage(named: "globe")),
347+
type: .Image(UIImage(named: "globe", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
348348
style: DefaultKeyboardGlobeButtonStyle,
349349
width: .Static(width: 40),
350350
identifier: DefaultKeyboardIdentifier.Globe.rawValue),
@@ -416,7 +416,7 @@ public enum DefaultKeyboardLayout {
416416
]
417417
),
418418
KeyboardButton(
419-
type: .Image(UIImage(named: "backspace")),
419+
type: .Image(UIImage(named: "backspace", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
420420
style: DefaultKeyboardBackspaceButtonStyle,
421421
width: .Relative(percent: 0.13),
422422
identifier: DefaultKeyboardIdentifier.Backspace.rawValue),
@@ -431,7 +431,7 @@ public enum DefaultKeyboardLayout {
431431
width: .Relative(percent: 0.13),
432432
identifier: DefaultKeyboardIdentifier.Letters.rawValue),
433433
KeyboardButton(
434-
type: .Image(UIImage(named: "globe")),
434+
type: .Image(UIImage(named: "globe", inBundle: NSBundle(forClass: DefaultKeyboard.self), compatibleWithTraitCollection: nil)),
435435
style: DefaultKeyboardGlobeButtonStyle,
436436
width: .Static(width: 40),
437437
identifier: DefaultKeyboardIdentifier.Globe.rawValue),

0 commit comments

Comments
 (0)