-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use Predicate<T> instead of creating a new interface that extends it.…
… Fix tooltips. See https://gist.github.com/gigaherz/7efeb2c17b05c179b970e4e0d3727714 for an example of the new pagination and conditions stuff.
- Loading branch information
Showing
26 changed files
with
410 additions
and
142 deletions.
There are no files selected for viewing
204 changes: 146 additions & 58 deletions
204
src/main/java/gigaherz/guidebook/guidebook/BookDocument.java
Large diffs are not rendered by default.
Oops, something went wrong.
10 changes: 10 additions & 0 deletions
10
src/main/java/gigaherz/guidebook/guidebook/IConditionSource.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package gigaherz.guidebook.guidebook; | ||
|
||
import gigaherz.guidebook.guidebook.conditions.ConditionContext; | ||
|
||
import java.util.function.Predicate; | ||
|
||
public interface IConditionSource | ||
{ | ||
Predicate<ConditionContext> getCondition(String name); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 0 additions & 8 deletions
8
src/main/java/gigaherz/guidebook/guidebook/conditions/IDisplayCondition.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
src/main/java/gigaherz/guidebook/guidebook/drawing/VisualChapter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package gigaherz.guidebook.guidebook.drawing; | ||
|
||
import com.google.common.collect.Lists; | ||
import com.google.common.collect.Maps; | ||
|
||
import java.util.List; | ||
import java.util.Map; | ||
|
||
public class VisualChapter | ||
{ | ||
public final List<VisualPage> pages = Lists.newArrayList(); | ||
public final Map<String, Integer> pagesByName = Maps.newHashMap(); | ||
public int startPair; | ||
public int totalPairs; | ||
} |
17 changes: 17 additions & 0 deletions
17
src/main/java/gigaherz/guidebook/guidebook/drawing/VisualPageBreak.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package gigaherz.guidebook.guidebook.drawing; | ||
|
||
import gigaherz.guidebook.guidebook.IBookGraphics; | ||
|
||
public class VisualPageBreak extends VisualElement | ||
{ | ||
public VisualPageBreak(Size size) | ||
{ | ||
super(size); | ||
} | ||
|
||
@Override | ||
public void draw(IBookGraphics nav) | ||
{ | ||
// not a drawableelement | ||
} | ||
} |
Oops, something went wrong.