Skip to content

Review Task 1 - #1

Open
fracz wants to merge 1 commit into
BrtqKr:masterfrom
fracz:task1
Open

Review Task 1#1
fracz wants to merge 1 commit into
BrtqKr:masterfrom
fracz:task1

Conversation

@fracz

@fracz fracz commented Mar 24, 2020

Copy link
Copy Markdown

Find as many defects and problems as possible!

@SuppressLint("ViewConstructor")
public class Line extends LinearLayout implements Serializable {
private static final long serialVersionUID = 3076583280108678995L;
private static final int TWO = 2;

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Niepotrzebna stała

// public void addVideoComment(File videoFile) throws CommentNotAddedException {
// }

private void addLineContent(boolean syntaxColor){

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Parametr typu boolean

import java.util.List;

/**
* View that represents one line of code.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bezużyteczny komentarz


/*
2013-10-23, fracz, first implementation
2013-10-30, fracz, added syntax highlighting

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Historię można przejrzeć na gicie, komentarze śmiecą

lineNumberView.setBackgroundColor(Color.parseColor("#008000"));
}
}

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Zakomentowany, niewykorzystany kod (pewnie niedokończony albo pozostałość z refaktoryzacji)

Comment voiceComment = new Comment(AbstractComment.Type.VOICE, this);
voiceComment.setFile(recodedFile);
comments.add(voiceComment);
if (comments.size() > 0) {

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Łamie srp

private void addLineContent(boolean syntaxColor){
if (!syntaxColor || !SyntaxHighlighter.canBeHighlighted(syntaxColor))
lineContent.setText(Html.fromHtml(lineOfCode));
else

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Godline

*/
@SuppressLint("ViewConstructor")
public class Line extends LinearLayout implements Serializable {
private static final long serialVersionUID = 3076583280108678995L;

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Niepotrzebny typ prymitywny

setOrientation(LinearLayout.HORIZONTAL);

lineNumberView = new TextView(getContext());
lineNumberView.setText(String.format("%d.", lineNumber););

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Brak kompilacji

// }

private void addLineContent(boolean syntaxColor){
if (!syntaxColor || !SyntaxHighlighter.canBeHighlighted(syntaxColor))

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Można uprościć wyrażenie logiczne

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants