Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'd like to empty the Active Block list of hosts from this productivity software called SelfControl (anyone knows about it?) because some of these websites are duplicates. I've tried pressing Del key, right-clicking on the website entries, dragging them into the main window and then pressing the "Delete" button -- nothing works. Is there some work-around? Should I modify some configuration file with my sudo privileges? I downloded the application as a *.deb package from the official site. I'm including 2 screen-shots.

main window block list

share|improve this question
add comment

1 Answer 1

After much searching, here's how I solved the problem.

  1. Type in Terminal: sudo gedit /usr/share/perl5/SelfControl/UI.pm
  2. Place cursor after $list->set_data_array($self->{config}->{hosts}); $list->get_selection->set_mode('multiple');
  3. Copy & paste this code: # we need the following line otherwise the list is too small $list->set_size_request(350,500);

    my @columns = $list->get_columns; my $cnum = scalar(@columns); my $c; foreach $c (@columns) { $c->set_resizable(TRUE); }

    my $rows = $self->{config}->{hosts}; my $rnum = scalar(@$rows);

    if ($rnum > 10){ $rnum = 10; } if ($rnum < 2){ $rnum = 2; }

    $list->set_size_request (175 * $cnum, 28 * $rnum);

  4. Save and close Gedit
  5. Try launching the app and see if it works.
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.