Alright, so assuming that content is the JPanel, here's what I usually do to create a JPanel that will be added to the JFrame. I don't think you should create JPanel as it's own class other than instantiate and set whatever variables within the JPanel as needed:
Code:
JPanel content = new JPanel();
content.setLayout(new BorderLayout(5, 5));
content.add(changeColorBtn, BorderLayout.NORTH);
content.add(left, BorderLayout.WEST);
content.add(rite, BorderLayout.EAST);
/* .. somewhere later you need to add this JPanel named "content" to the JFrame e.g. add(buttonPanel, BorderLayout.CENTER); */ hope that helps!
