2009年5月30日星期六

Aptana Plugin For Eclipse 1.2.7 破解

针对最新的aptana_update_024747,可以从 http://www.aptana.com/download/下载并安装。

安装完成后,在eclipse/plugins目录中找到 com.aptana.ide.core_1.2.7.024747.jar

用jad或者相关反编译软件反编译 com.aptana.ide.core.licensing.ClientKey 这个类,我用的是 http://proglife.yo2.cn/articles/eclipse%E4%B8%8B%E7%9A%84%E5%8F%8D%E7%BC%96%E8%AF%91%E6%96%B9%E6%A1%88.html 里边的方案进行反编译的。

新建一个Java类ClientKey,将反编译出来的代码粘贴到这个类中,并修改如下:

package com.aptana.ide.core.licensing;

import java.util.Calendar;
import java.util.TimeZone;

public final class ClientKey
{
  public static final String BEGIN_LICENSE_MARKER = "--begin-aptana-license--";
  public static final String END_LICENSE_MARKER = "--end-aptana-license--";
  public static final int PRO = 0;
  public static final int TRIAL = 1;
  private static final TimeZone GMT = TimeZone.getTimeZone("GMT");
  public static final String EMAILS_NON_MATCHING = "EMAILS_NON_MATCHING";
  public static final ClientKey EMPTY_KEY = new ClientKey(1, "any@gmail.com", 0L);
  private String email;
  private long expiration;
  private int type;

  public ClientKey(int type, String email, long expiration)
  {
    this.type = type;
    this.email = email;
    this.expiration = expiration;
  }

  public boolean isCloseToExpiring()
  {
    return false;
  }

  public boolean isValid()
  {
    return true;
  }

  public boolean isCloseToMatching()
  {
    return true;
  }

  public boolean isExpired()
  {
   return false;
  }

  public String getEmail()
  {
      return "any@gmail.com";
  }

  public Calendar getExpiration()
  {
    Calendar expirationCal = Calendar.getInstance();
    expirationCal.add(Calendar.YEAR, 50);
    return expirationCal;
  }

  public boolean isTrial()
  {
    return false;
  }

  public boolean isPro()
  {
    return (!(isTrial()));
  }

  public boolean shouldProPluginsRun()
  {
    if (isPro())
    {
      return true;
    }
    return (!(isExpired()));
  }

  public static String trimEncryptedLicense(String encrypted)
  {
    String newEncrypted = encrypted;
    newEncrypted = newEncrypted.trim();
    newEncrypted = newEncrypted.replaceAll("--begin-aptana-license--", "");
    newEncrypted = newEncrypted.replaceAll("--end-aptana-license--", "");
    newEncrypted = newEncrypted.replaceAll("\\s+", "");
    return newEncrypted;
  }
}

注意红色的是修改的部分。

编译该文件,并用生成的class文件替换com.aptana.ide.core_1.2.7.024747.jar中的ClientKey.class文件。(可用winrar打开后直接拖进去覆盖)。

重新启动eclipse即可生效。效果图如下:

1

2009年5月28日星期四

[整理] 解决digital tv link多换台几次后无声或者无响应的方法

1、在换台前,点击播放器的停止播放按钮停止当前频道的播放,然后用digital tv link 换台,最后点击播放器的播放按钮来播放;

2、经过检查发现,digita tv link 播放时会在dm500s中创建2个streampes 进程,换台时又会再创建2个,这样多次换台,你的dm500s的资源就将耗尽,并出现无声等现象。而,停止键会关闭创建的streampes进程, 这样就不会出现耗费资源的状况了。

你也可以telnet 到dm 上把无响应的streampes进程kill掉,不用重启主机也可以了.

killall streampes