Skip to content

Commit ab5e293

Browse files
author
zhenya
committed
no comments
1 parent cc0fc9c commit ab5e293

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

src/main/java/com/iusenko/subrip/Phrase.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@
77
public class Phrase {
88
public static final Phrase END = new Phrase();
99

10-
private int id;
11-
private long startTime;
12-
private long endTime;
13-
private String startTimeText;
14-
private String endTimeText;
15-
private String text;
10+
public int id;
11+
public long startTime;
12+
public long endTime;
13+
public String startTimeText;
14+
public String endTimeText;
15+
public String text;
1616

1717
public long getEndTime() {
1818
return endTime;

src/main/java/com/iusenko/subrip/PhraseUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ public class PhraseUtils {
66

77
public static Phrase find(long timestamp, List<Phrase> phrases) {
88
for (Phrase phrase : phrases) {
9-
if (phrase.getStartTime() >= timestamp
9+
if (phrase.getStartTime() <= timestamp
1010
&& timestamp <= phrase.getEndTime()) {
1111
return phrase;
1212
}

0 commit comments

Comments
 (0)